cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ramiz
Helper III
Helper III

Current Date problem in Flow

Hi,
I have created a flow and I am using a formula formatDateTime(utcNow(),'yyyy-MM-dd')  to get current date.

The problem is my flow is a recurrence and when it runs at the specified time its not calculating the current date but when I am running it manually by clicking the start button its giving me correct and current date. 
As you can see in the below images the same flow ran on the same date but different time and its giving different date using the formula i mentioned above. 

Screenshot_1.png

 

Screenshot_2.png

1 ACCEPTED SOLUTION

Accepted Solutions
Jcook
Super User
Super User

Hello @Ramiz 

 

Try this expression:

 

convertFromUtc(utcNow(), 'Arab Standard Time', 'yyyy-MM-dd')


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

If you like my post please hit the Thumbs Up


Proud to be a Flownaut!


Check out my blog for Power Automate tips,
tricks, and guides
FlowAltDelete





View solution in original post

5 REPLIES 5
Mira_Ghaly
Dual Super User II
Dual Super User II

@Ramiz

Please check the time zone on your recurrence trigger

If this post helps you with your problem, please mark your as Accepted solution.If you like my response, please give it a Thumbs Up.

Blog: here

Hi @Mira_Ghaly 

Thanks for the answer but i didnt select any timezone in the recurrence trigger but now I have selected the timezone and will test it.

@Mira_Ghaly  I tested with time zone as well but still its giving me wrong date.


Screenshot_1.png

Jcook
Super User
Super User

Hello @Ramiz 

 

Try this expression:

 

convertFromUtc(utcNow(), 'Arab Standard Time', 'yyyy-MM-dd')


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

If you like my post please hit the Thumbs Up


Proud to be a Flownaut!


Check out my blog for Power Automate tips,
tricks, and guides
FlowAltDelete





View solution in original post

@Jcook  I tested with this and it worked. Thanks for the answer.

Helpful resources

Announcements
UG GA Amplification 768x460.png

Launching new user group features

Learn how to create your own user groups today!

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

M365 768x460.jpg

Microsoft 365 Collaboration Conference | December 7–9, 2021

Join us, in-person, December 7–9 in Las Vegas, for the largest gathering of the Microsoft community in the world.

Top Solution Authors
Users online (2,021)