I am trying to set the active stage of my business process flow when my condition is false. However I am getting the "work flow with ID <> does not exist." error even when the stage ID is correct.
Here is my JS code
And here is the ID of the stage I would like to set active.
Please go through the link: https://carldesouza.com/using-javascript-to-go-to-next-stage-in-business-process-flows/. It will help you a lot.
Let me know if I can help you more.
Thanks
Regards,
Abdul Wahab
Hi kthlnvrgna,
You are using setActiveProcess which is incorrect. This method is used to set an Active BPF to the record,
In your case you should use setActiveStage like below
formContext.data.process.setActiveStage(stageId, callbackFunction);
https://docs.microsoft.com/en-us/powerapps/developer/model-driven-apps/clientapi/reference/formcontext-data-process/activestage/setactivestage
If this answers your question, please mark my answer as verified
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.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Rishabh Kanaskar 258
MVP-Daniyal Khaleel 165
Tom_Gioielli 148 Super User 2025 Season 2