Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Answered

Starting a flow of Power Automate when entering in an Opportunity

(0) ShareShare
ReportReport
Posted on by 448

Hi all,

It's possible to start a flow of Power Automate every time that user is entering in an Opportunity?
If yes, can somebody indicate me some example?

Thanks in advance

  • Verified answer
    Pradeep Rai Profile Picture
    Pradeep Rai 5,480 Super User 2024 Season 2 on at
    RE: Starting a flow of Power Automate when entering in an Opportunity

    Hi,

    1. For creating custom fields: https://www.gestisoft.com/blog/how-to-add-fields-in-microsoft-dynamics-365

    2. add below function onload

    function onLoad(executionContext)
    {
    var formContext=executionContext.getFormContext();

    var fieldValue=formContext.getAttribute("<add logical name of newly created field>").getValue();

    formContext.getAttribute("<add logical name of newly created field>").setValue(!fieldValue);

    formContext.data.entity.save();

    }

    3. Power Automate: add field below highlighted part:

    pastedimage1673546549596v1.png

    Thank You,
    Pradeep Rai.

    Please mark the answer VERIFIED, if it helps.

  • DiePic Profile Picture
    DiePic 448 on at
    RE: Starting a flow of Power Automate when entering in an Opportunity

    Thanks for reply Pradeep Rai

    can you indicate me some link with examples please or some where I can find a detailed lesson about?

  • Suggested answer
    Pradeep Rai Profile Picture
    Pradeep Rai 5,480 Super User 2024 Season 2 on at
    RE: Starting a flow of Power Automate when entering in an Opportunity

    Hi,

    Entering means user open the opportunity manually, if yes then you need to create one field Two Options then with javascript you can update the values by toggling them with form onload event.

    and on update of this field you can run power automate.

    Other way, is on create of opportunity you can write power automate.

    Thank You,

    Pradeep Rai.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Congratulations 2024 Spotlight Honorees!

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December!

Congratulations to our December super stars! 🥳

Get Started Blogging in the Community

Hosted or syndicated blogging is available! ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,642 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,371 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans