Back to Basics # 28: Call Action from BPF in Dynamics CRM
Introduction:
We can enhance BPF so that an Action can be called in between stages. So here, in this post we see in the same vaccination use case send an email to selected contact in the initial stage.
Step 1:
Login to the required environment and go to flows and select Business process flows – Vaccination as shown in the below figure.

Step 2:
After Step 1 , in Vaccination BPF ,select Contact Vaccinated Stage and go to components and drag and drop Action Step and name it as Email Action as shown in the below figure.

Step 3:
After Step 2 , under Email Action Step as I have already created workflow before Sequence will be 2 and under Execute Process -> Select Discount Action and under Input Parameters select Email as one field and click on Apply as shown in the below figure.

Step 4:
After Step 3, in case if existing action is not available then action Discount Action can be created with an input parameter as Email of string type and under steps select Email step and configure email and click on Save and Activate Action with the following details as shown in the below figure.

Step 5:
After Step 4, publish all customizations and open contact record and go to Vaccinated Stage and select Email Action and click on Execute , a new popup will be shown with Email value pre-populated [email which is present on the contact record] and click on Execute as shown in the below figure.

Step 6:
After Step 5, after execution we can observe Email Action get successfully executed with a green colour tick mark as shown in the below figure.

Step 7:
After Step 6, refresh record and observe Time line you should see a new email activity got created which is fired from CRM Action as shown in the below figure.

Note:
- Make sure every stage and data steps are discussed before implementation.
- Validate, Save and Activate BPF without fail.
- During creation of Action, make sure option under Available to Run -> As a Business Process Flow action step.
- Make sure to Activate Action and also give importance to CRN Action’s Input and Output Parameters.
- BPF’s works only in Modern Driven Apps.
Conclusion: In this way, one can easily call Action from Business Process Flow in Dynamics CRM.
This was originally posted here.
*This post is locked for comments