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,...
Unanswered

Get order of processtages without traversedpath / RetrieveActivePathResponse of BPF

(0) ShareShare
ReportReport
Posted on by 115

I am struggeling with an edge case i guess. 

I wrote a plugin that determines the active processstage of an opportunity. It reads the active process from the "userentityuisettings" table and than gets the processstage from all active BPF revieved by using "RetrieveProcessInstancesRequest". So it work even if i got multiple active processes on an opportunity and switch from one to another in the frontend.

If i delete a processstage in the bpf editor which still holds opportunities, the frontend falls back to the first processstage in the process but it seems that it is not realy activting the first processtage. I want to fallback in c# too but the opportunity itself respectively its businessprocessflowinstance will still show the delted processstage-guid in "processstageid". So i cannot use that. "traversedpath" is an emtpy string and RetrieveActivePathResponse will return an empty collection so i cannot use that too. It seems the only possible way to get the first stage which is shown in the frontend would be to get all processtages of the bpf itself in the order of the process and then grab the first item. But i dont know how to do that. How to achieve that without using "RetrieveActivePathResponse" of a businessprocessflowinstance?


Where is the order information even stored? Or is there a way to retrieve the defaultPath from the BPF not the instance?


EDIT: It seems that the process information itself is located in the workflow table. Column "xaml". How to parse the XAML of a business process flow?

The documentation for the loader shows an example with type <int> but i guess it has to be something workflow specific in this case?

DynamicActivity wf = ActivityXamlServices.Load(new StringReader(serializedAB)) as DynamicActivity;


docs.microsoft.com/.../serializing-workflows-and-activities-to-and-from-xaml

I have the same question (0)

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 108 Super User 2025 Season 2

#2
Jimmy Passeti Profile Picture

Jimmy Passeti 50 Most Valuable Professional

#3
Gerardo Rentería García Profile Picture

Gerardo Rentería Ga... 49 Most Valuable Professional

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans