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 :
Microsoft Dynamics CRM (Archived)

How to automatically Finish a workflow

(0) ShareShare
ReportReport
Posted on by 245

I have a workflow business process flow, and the last stage is called Certification, and this stage contains 3 required steps.

What I wanted to do is after I completed the 3 steps in the Certification stage, and save it, I want the stage to automatically FINISH, instead of manually clicking it.

Any ideas with using any custom code (plugin).

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    gdas Profile Picture
    50,091 Moderator on at

    Hi,

    I believe you can do this using workflow or action based on field value -

    Check here form more info -

    dynamics365blocks.wordpress.com/.../how-to-change-bpf-stages-automatically-using-workflow-in-dynamics-365

    community.dynamics.com/.../258175

  • Suggested answer
    StefanS365 Profile Picture
    3,575 Most Valuable Professional on at

    Hi Benjamin,

    You could add a workflow to the base entity of the business process flow that is triggered by the change of the 3 steps / fields and then set the status of the business process flow record to finished/completed.

    Reference: blogs.msdn.microsoft.com/.../automate-business-process-flow-stages-using-workflows

  • Benjamin Fallar III Profile Picture
    245 on at

    I'm referring to the FINISH button on the last stage. I'm not referring to changing stage.

  • Suggested answer
    Priyesh Profile Picture
    7,396 User Group Leader on at

    Hi,

    Yes, you can write a plugin on the BPF entity itself. Here's the high level approach you can go for -

    1. Write a plugin on the change of either of the three/four fields on Opportunity/Lead (or wherever your process is)

    2. The plugin will query the BPF record where the context of the plugin record i.e. the record in question is is set to Opportunity/Lead (respective field).

    3. Update the Status Reason to completed of that BPF.

    Keep the plugin Sync so you can see it being updated.

    Hope this helps.

  • Benjamin Fallar III Profile Picture
    245 on at

    I already got into that document, but I didn't get your statement on how to set the status of the BPF to complete. There is no settings in the Update of the BPF entity.

  • Benjamin Fallar III Profile Picture
    245 on at

    Oh, I'm sorry... I mean NO custom plugin code.

  • Benjamin Fallar III Profile Picture
    245 on at

    and the only available status reason are active and inactive.

  • Suggested answer
    Sreevalli Profile Picture
    3,256 on at

    Hi,

    I didn't try this but you can give a try

    community.dynamics.com/.../finish-a-business-process-flow-in-c

  • Suggested answer
    StefanS365 Profile Picture
    3,575 Most Valuable Professional on at

    You should use the workflow action step Change status of record where you can select the status reason.

  • Suggested answer
    Kokulan Profile Picture
    18,054 on at

    Hi, could you try the following and see if does what you want to achieve

    Create a workflow on BPF process change (select Modified On) field, this will trigger the workflow everytime a step is updated.

    In the workflow, you can check the active stage and also check all three fields if they have value by checking the related entity fields.

    If those three steps have value and if the BPF Active stage is correct, you can then do an Update to BPF entity record and set the Active Stage to the Finished or Last stage you want to move it to.

    ScreenClip-_5B00_49_5D00_.png

    ScreenClip-_5B00_49_5D00_.png

    Thanks

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 > 🔒一 Microsoft Dynamics CRM (Archived)

#1
SA-08121319-0 Profile Picture

SA-08121319-0 4

#1
Calum MacFarlane Profile Picture

Calum MacFarlane 4

#3
Alex Fun Wei Jie Profile Picture

Alex Fun Wei Jie 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans