We have been using workflow to set/update Business Process Flow (BPF) when a record is created or updated and even with some conditions.
Business Requirement: We had a business requirement in the past to set Business Process Flow (BPF) when an opportunity is created with a specific condition. We created a workflow to set the specific stage and worked fine in the Dev instance
Problem: When the solution moved to another instance workflow is not published even though it has set up to publish. Many of us remember we fix those workflows on deployment time. The Reason was workflow has BPF stage id is not matching with another environment.
Solution: Other possible solutions are Client API / Javascript or Plugin previously. Now we can solve this issue using power automate
Key Advantages:
- Use Microsoft recommended solution
- No custom code
- No GUID mismatch Issue for each environment
Step 1: Create a New “Cloud flow”
- Select connector: Common Data Service (current environment)
- Select Trigger: When a row is created, updated, or deleted
Step 2: Define the steps. Here is the flow diagram for the steps
Step 3: Save and Turn On
Test the Flow:
- Create the Lead
- Update Lead revenue greater than or equal to 50,000,000
- Qualify the lead
Verification:
An opportunity should be created with an Active stage “Propose” instead of “Qualify”
Source (Cloud FLow) – Click the below link to download the flow
UpdateOpportunitySalesStagetoProposeBasedonAnnualRevenue
A great idea! The provided download link does not work. Could you drop me a valid one
Hi Maris,
I have added the missing images and added the Power Automate to Git Repo. You can download now and let me know if any issues.