cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
New Member

Take current time and round up to nearest quarter hour

I need help with a flow app. I want to be able to take the current time, round that time up to the nearest quarter hour and then add 7 minutes to that time.  Then I want to delay the rest of my flow until that time comes. For example: Current time is 15:18, I want it to round up to 15:30 and then add 7 minutes to make it 15:37.  I then want to delay the rest of my flow until that time. 

 

 

2 ACCEPTED SOLUTIONS

Accepted Solutions
Community Support
Community Support

Hi @rtlane,

 

I am afraid that there is no round function can be used in flow currently, you may consider submitting a request on Flow Ideas forum for this function:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

Besides, you may try to use the function if to return the value you want according to the existing time. Please take this doc for more details about the function:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference

 

 

Best regards,

Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Thank you! I ended using a combo of if statements to accomplish this.

 

if(lessOrEquals(variables('Minutes'),15),add(sub(15,variables('Minutes')),7),if(and(greater(variables('Minutes'),15),lessOrEquals(variables('Minutes'),30)),add(sub(30,variables('Minutes')),7),if(and(greater(variables('Minutes'),30),lessOrEquals(variables('Minutes'),45)),add(sub(45,variables('Minutes')),7),if(greater(variables('Minutes'),45),add(sub(60,variables('Minutes')),7),0))))

View solution in original post

3 REPLIES 3
Community Support
Community Support

Hi @rtlane,

 

I am afraid that there is no round function can be used in flow currently, you may consider submitting a request on Flow Ideas forum for this function:

https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

 

Besides, you may try to use the function if to return the value you want according to the existing time. Please take this doc for more details about the function:

https://docs.microsoft.com/en-us/azure/logic-apps/workflow-definition-language-functions-reference

 

 

Best regards,

Mabel Mao

Community Support Team _ Mabel Mao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Hello, @rtlane!

 

If you have already posted your idea to the Flow Community Ideas Forum then you need to post the URL to your idea’s thread as a reply to this thread and then "Accept as Solution" on that reply so other users may vote for your Flow Idea and identify the information easily.

 

Thank You!

 

-Gabriel
Flow Community Manager

- Gabriel
Community Manager
Power Automate | Power Virtual Agents
Super User Program Manager
Power Platform Communities

Thank you! I ended using a combo of if statements to accomplish this.

 

if(lessOrEquals(variables('Minutes'),15),add(sub(15,variables('Minutes')),7),if(and(greater(variables('Minutes'),15),lessOrEquals(variables('Minutes'),30)),add(sub(30,variables('Minutes')),7),if(and(greater(variables('Minutes'),30),lessOrEquals(variables('Minutes'),45)),add(sub(45,variables('Minutes')),7),if(greater(variables('Minutes'),45),add(sub(60,variables('Minutes')),7),0))))

View solution in original post

Helpful resources

Announcements
PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

MPA Community Blog

Power Automate Community Blog

Check out the community blog page where you can find valuable learning material from community and product team members!

Top Solution Authors
Users online (9,527)