cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Flow Date/Time Formula

I'm creating a flow that creates a task when an email message is flagged. I would like to make a task due today. Currently, I have the utcNow() formula, but this make it due yesterday for some odd reason. 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Frequent Visitor

Re: Flow Date/Time Formula

Ok. After I slept on it and looked at my workflow output in the flow history, that makes since, but your solution wouldn't work either. This is a date output, not a time and date output so it was reading today's date and time, outputting it as midnight on that day (because the date field doesn't have a time), and then subtracting off hours out of the output (because I'm 5 hours behind UTC) and coming up with yesterday's date. In that case, no matter what time I put on there, it's going to output yesterday's date so I'll actually have to do an add a day formula. That's a glitch and should probably be fixed. Even if they created a "today" formula, it would still carry this issue. 

 

So my formula (UTC now) produced this: 2017-09-26T20:00:45.8026886Z

And the output became: 2017-09-26T00:00:00

And then outlook subtracted 5 hours and came up with yesterdays date. 

View solution in original post

2 REPLIES 2
Highlighted
Community Support
Community Support

Re: Flow Date/Time Formula

Hi @khartunguark,

 

I susepct the issue should be mostly related with the time zone.

Generally UTCNow() function would generate the current time in UTC time zone, if you would like to convert into your own time zone, please take a try to take use of AddHours() function to revert the time changes.

Function reference:

WorkFlow definition Language

 

Regards,

Michael

 

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Highlighted
Frequent Visitor

Re: Flow Date/Time Formula

Ok. After I slept on it and looked at my workflow output in the flow history, that makes since, but your solution wouldn't work either. This is a date output, not a time and date output so it was reading today's date and time, outputting it as midnight on that day (because the date field doesn't have a time), and then subtracting off hours out of the output (because I'm 5 hours behind UTC) and coming up with yesterday's date. In that case, no matter what time I put on there, it's going to output yesterday's date so I'll actually have to do an add a day formula. That's a glitch and should probably be fixed. Even if they created a "today" formula, it would still carry this issue. 

 

So my formula (UTC now) produced this: 2017-09-26T20:00:45.8026886Z

And the output became: 2017-09-26T00:00:00

And then outlook subtracted 5 hours and came up with yesterdays date. 

View solution in original post

Helpful resources

Announcements
firstImage

Super User Program Update

Three Super User rank tiers have been launched!

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

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
Users online (7,385)