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

I can't use formatDateTime help please

 Hi,

I want to use "formatDateTime" expression in my flow but I can't.  I tried below list:

 

"@formatDateTime(@{body('Start_an_approval')?['responseDate']},'yyyy-MM-dd')"

or

@formatDateTime(@{body('Start_an_approval')?['responseDate']},'yyyy-MM-dd')

or

formatDateTime(@{body('Start_an_approval')?['responseDate']},'yyyy-MM-dd')

or

=formatDateTime(@{body('Start_an_approval')?['responseDate']},'yyyy-MM-dd')

or

"=formatDateTime(@{body('Start_an_approval')?['responseDate']},'yyyy-MM-dd')"

 

but always get results with "@formatDateTime(2018-09-25T14:37:49.4671573Z,'yyyy-MM-dd')"

 

could you please help ?

 

my flow:

image.png

results:

image.png

I've checked ref. links below but I didn't success:

https://www.o365dude.com/2017/05/01/working-with-dates-times-in-microsoft-flow/

https://nicknow.net/microsoft-flow-dates-times-timezones-formatting/

https://powerusers.microsoft.com/t5/General-Discussion/PowerApps-to-Flow-Date-Format-problem/m-p/492...

https://powerusers.microsoft.com/t5/Connecting-To-Data/formatDateTime/m-p/24013

 

Regards,

2 REPLIES 2
Highlighted
Community Support
Community Support

Re: I can't use formatDateTime help please

Hi @OzanOZEN,

 

The expression should be as below:

"@formatDateTime(body('Start_an_approval')?['responseDate'],'yyyy-MM-dd')"

I have made a test on my side and have created a flow as below:

Capture.PNG

 

The flow would run successfully as below:

Capture.PNG

 

 

Best regards,

Alice

 

Highlighted
New Member

Re: I can't use formatDateTime help please

Hi @v-yuazh-msft

Thank you for reply. I tried on my flow but results same. Could you pleaes check my flow and results:

I used MS forms integrated.

 

flow:

image.png

 

results:

image.png

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
Top Kudoed Authors
Users online (8,003)