cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Advocate II
Advocate II

Timed Delegation

Hi,

 

I have a Flow operating on a SharePoint (O365) List. My Flow sends an Approval request to Person1. Using a Condition and an Update, if Person1 Approves, then the Flow will set Status = Approved in the list; if Person1 Rejects, then the Flow will set Status = Rejected.

 

I need my Flow to redirect to Person2 if Person1 does not respond to the Approval request (either Accept or Reject) within 48 hours (i.e. Now() > CreateDate + 2d). How can I do this?

 

I've experimented with Time Outs and Run After configurations but can only get the flow to complete if the original Approval request times out - if the original request is responded to, the Run History shows as "Succeeded" but the Flow shows the following error in the following Condition: "ActionConditionFailed. The execution of template action 'Condition' is skipped: the 'runAfter' condition for action 'Delegate' is not satisfied. Expected status values 'Succeeded' and actual value 'Skipped'."

 

I think I understand why this message is displayed, but can’t work out the logic to handle the “Normal” flow and the “Time Out” flow.

 

Any help gratefully received

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Advocate II
Advocate II

Re: Timed Delegation

I've resolved my issue with the following solution:

 

Create an Approval action – call this “Review”

Create another Approval action directly below, for the delegation – call this “Delegated Review”

Create an Update action underneath to update your list based on the “Delegated Review” outcome – call this “Update Post Delegated Review”

Create a parallel branch (alongside the “Delegated Review” action) and add an Update action to update your list based on the “Review” – call this “Update Post Review”

Create an action (in my example a send e-mail action) to bring the two branches back together – call this “Outcome”

 

DelegatedApproval.PNG

 

Go back and change settings for the “Review” action to time out after PT2M (2 minutes – for testing) or PT48H (48 hours for real).

 

TimeOut.PNG

 

“Configure run after” for the “Delegated Review” to only run if the “Review” has timed out

 

RunAfter1.PNG

 

“Configure run after” for the “Outcome” to run if the “Review” OR the “Delegated Review” have been skipped, OR either have been successful.

 

RunAfter2.PNG

 

All other settings in all other actions are left as their default.

 

If the “Review” is successful (i.e. if the recipient reacts within the timeframe) the “Update Post Review” will be called and the “Delegated Review” branch, including the update beneath, will be ignored (skipped).

 

If the “Review” times out (i.e. if the recipient does not react within the timeframe) the “Delegated Review” branch, including the update beneath, will be called.

 

The “Outcome” action ties the two branches together.

 

Hope that helps some people out there.  Let me know if it does!

View solution in original post

5 REPLIES 5
Highlighted

Re: Timed Delegation

Hi @Mupps,

 

I think you've got 2 problems to sort out.

 

1. retrying tasks

 

Have a look at this post:

https://veenstra.me.uk/2018/02/07/microsoft-flow-implementing-a-try-catch-finally-in-a-flow/

 

You don't have to use scopess as I described you can simply use Do-Until steps or just two approval steps after eachother with the right runafter configurations set.

 

2. Organise your flow to make it status driven:

 

See my post here:

https://powerusers.microsoft.com/t5/Microsoft-Flow-Community-Blog/Develop-Flows-Like-a-Pro/ba-p/8989...

 

 

Highlighted
Advocate II
Advocate II

Re: Timed Delegation

Many thanks @Pieter_Veenstra  I've been working on this today and have made progress.  I'll feedback when I have a solution.

Highlighted
Advocate II
Advocate II

Re: Timed Delegation

I've resolved my issue with the following solution:

 

Create an Approval action – call this “Review”

Create another Approval action directly below, for the delegation – call this “Delegated Review”

Create an Update action underneath to update your list based on the “Delegated Review” outcome – call this “Update Post Delegated Review”

Create a parallel branch (alongside the “Delegated Review” action) and add an Update action to update your list based on the “Review” – call this “Update Post Review”

Create an action (in my example a send e-mail action) to bring the two branches back together – call this “Outcome”

 

DelegatedApproval.PNG

 

Go back and change settings for the “Review” action to time out after PT2M (2 minutes – for testing) or PT48H (48 hours for real).

 

TimeOut.PNG

 

“Configure run after” for the “Delegated Review” to only run if the “Review” has timed out

 

RunAfter1.PNG

 

“Configure run after” for the “Outcome” to run if the “Review” OR the “Delegated Review” have been skipped, OR either have been successful.

 

RunAfter2.PNG

 

All other settings in all other actions are left as their default.

 

If the “Review” is successful (i.e. if the recipient reacts within the timeframe) the “Update Post Review” will be called and the “Delegated Review” branch, including the update beneath, will be ignored (skipped).

 

If the “Review” times out (i.e. if the recipient does not react within the timeframe) the “Delegated Review” branch, including the update beneath, will be called.

 

The “Outcome” action ties the two branches together.

 

Hope that helps some people out there.  Let me know if it does!

View solution in original post

Highlighted
Community Support
Community Support

Re: Timed Delegation

Hi @Mupps,

 

Have you solved your problem?

Do you have any questions about Microsoft Flow?

 

Thanks for your sharing, the solution that you provided inspire me a lot. In addition, you could also consider take a try with the following workaround:11.JPG

 

Within right parallel branch, add a "Delay" action, Count set to 2 and Unit set to Day.

 

More details about adding parallel branches within Microsoft Flow, please check the following article:

Add parallel branches in flows

 

Best regards,

Kris

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Advocate II
Advocate II

Re: Timed Delegation

Hi Kris,

 

Thanks for your contribution.

 

I think that your suggestion will not provide a satisfactory solution.  Your two branches do not join back together, suggesting that there would be two separate Approval processes.  One would start two days after the other, but once started, it would not influence the first.  The first could be rejected, and two days later the second could be approved.

 

Having both the Time Out (which allows the stage to be skipped) and the converging of the branches with the correct conditions set is key to having an approval conducted by one recipient OR another.

Helpful resources

Announcements
firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

firstImage

Join the new Power Virtual Agents Community!

We are excited to announce the launch of Power Virtual Agents Community. Check it out now!

firstImage

New & Improved Power Automate Community Cookbook

We've updated and improved the layout and uploading format of the Power Automate Cookbook!

thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

Top Solution Authors
Top Kudoed Authors
Users online (7,620)