cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ravinovaworks
Level: Power Up

UtcNow and SharePoint Online List's Date Column

Hi,

I am using flow in Australia.

 

I have a SharePoint Online List that has an Expiry Date. I have configured Flow to send emails to responsible officers every morning using a condition: If the expiry date is today.

I have used the following syntax,

@equals(item()?['Item_x0020_Expires_x0020_On'],utcnow('yyyy-MM-dd')).

 

It appears to be working but the officers are receiving the email a day before the expiry date. If the expiry date is 13th, the emails are getting sent out on the 12th itself.. Iis this due to the utcnow() ? 

Please not that our tenant was hosted in South East Australia and regioinal settings in sharepoint were set to Melbourne, Australia.

 

Any help would be greatly appreciated.

 

Thank you

Ravi

1 REPLY 1
Super User
Super User

Re: UtcNow and SharePoint Online List's Date Column

Hi,

 

Can try converting the UTC to localtime using TimeZone.CurrentTimeZone.ToLocalTime(utcnow('yyyy-MM-dd')). I haven't tested this so not sure this is going to work or not?

 

Reference:

https://msdn.microsoft.com/en-us/library/system.timezone.tolocaltime(v=vs.110).aspx

 

Thanks

 



Did I answer your question? Mark my post as a solution!

If you liked my response, please consider giving it a thumbs up


Proud to be a Flownaut!



Helpful resources

Announcements
firstImage

Better Together Contest Finalists Announced!

Congrats to the finalists of our ‘Better Together’-themed T-shirt design contest! Click for the top entries.

firstImage

Incoming: New and improved badges!

Look out for new contribution recognition badges coming SOON!

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!

sixthImage

Community Summit North America

The top training and networking event across the globe for Microsoft Business Applications

Top Kudoed Authors
Users online (7,864)