web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

How to refresh the form Automatically after status change?

(0) ShareShare
ReportReport
Posted on by 115

Hi,

I have a BPF in orders entity. Once we click on the last stage of the BPF, the status of the record will change to submitted. I want to refresh the form as soon as this happens. Since I am not changing the status manually, I can't trigger a JS on change of Status field. Is there any way to achieve my requirement?

Thanks.

I have the same question (0)
  • Verified answer
    Ankit Sabharwal Profile Picture
    on at

    Hy Partner,

    Hope this post finds you well. You can register the javascript on Onload of the form with event handler defined in the function. Event handler name is addOnStageChange() : https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/clientapi/reference/formcontext-data-process/eventhandlers/addonstagechange

    Once it is register,it will fire the function register in the above event.

    In this function check if active stage is the last stage. Compare it with name of the stage and if it satisfies , you can refresh the form.You can also check the status of the record as well along with this condition and fire the refresh.

    For getting active stage name : https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/clientapi/reference/formcontext-data-process/activestage/getactivestage

    For refreshing the form : https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/clientapi/reference/formcontext-data/refresh

    Hope this helps.

    Best regards,

    Ankit

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Tom_Gioielli Profile Picture

Tom_Gioielli 170 Super User 2025 Season 2

#2
#ManoVerse Profile Picture

#ManoVerse 70

#3
Jimmy Passeti Profile Picture

Jimmy Passeti 50 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans