Hi all,
I am trying to build a flow for this process: When a service request is submitted, if it is in Top priority, it needs to be fixed in 15 mins.
After 15 mins, if the case is still not closed, send an reminder email to the staff (1st reminder).
After the 1st reminder is sent, the staff will receive reminder email every 5 mins until status changes to Closed.
Here's my design, the problem is: Using Do until, email will be sent before checking the condition inside the loop. I think a do while loop might be more suitable but no idea how to build. Any help?
Solved! Go to Solution.
Hi @leungar2 ,
The first method is to use the Delay action for five minutes after sending the reminder for the first time and then use the Get item action to get the current status value and assign the value to the variable.
Then add Condition to Do until, if the variable value is Closed, then the following action is not performed.
The second method is to add a reminder statement in the email, telling the user to ignore the email directly if the relevant operation has been completed.
Best Regards,
The status Value you are using in the do until, is not the value from the Get Items - this is outside of the context.
Use a variable instead and update the variable after the get items with the latest value.
i.e. create a variable, use that in your do until and then if the value is what you need, update the value of the variable to break the loop
Hi @Gristy
What do you mean by "not the value from the Get Items"? The status value is from "Get item 2"
hover over the Status value, it will no way be Get Item 2, as it would never let you save the flow.
you need to add a Initlize Variable at the top and a Set Variable under get item 2 to change it if the status value is closed for this flow to work ๐
Hi @leungar2 ,
Your Flow can basically cover your needs, you just need to use variables to store the current status value. And rely on this variable to end the loop.
Image reference:
Best Regards,
Hi @v-bacao-msft, @Gristy
Thanks so much for your help. I modified the flow a little bit but there's still a problem.
This is my process:
After 15 mins, if the case is still not closed, send an reminder email to the staff (1st reminder).
After the 1st reminder is sent, the staff will receive reminder email every 5 mins until status changes to Closed.
The problem now is: Reminder1 and Reminder2 will be sent out at the same time, seems Do until will do actions before checking the condition. Any thoughts?
Hi @leungar2 ,
The first method is to use the Delay action for five minutes after sending the reminder for the first time and then use the Get item action to get the current status value and assign the value to the variable.
Then add Condition to Do until, if the variable value is Closed, then the following action is not performed.
The second method is to add a reminder statement in the email, telling the user to ignore the email directly if the relevant operation has been completed.
Best Regards,
No, it is your logic.
You do not need reminder1 at all. If you do want to keep two seperate emails then move the delay above reminder2.
Hi @Gristy , @v-bacao-msft
Thank you all for your help! It's now running good! In case anyone got similar problem, below is the full flow for your reference
Join digitally, March 2โ4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!
User | Count |
---|---|
85 | |
57 | |
42 | |
37 | |
33 |
User | Count |
---|---|
91 | |
73 | |
72 | |
60 | |
40 |