cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ananda
Resolver I
Resolver I

Passing date into Flow as parameter throwing error for SharePoint date column.

Passing date into Flow as parameter throwing error for SharePoint date column.
PowerApp Code -

Text(DataCardValue13.SelectedDate,"[$-en-US]mm/dd/yyyy","en-US")

Error - string 'mm/dd/yyyy/' does not validate against format date,

In flow I've also used formatdatetime.

Code - formatdatetime(triggerBody()['Updatefileproperties_EndDate'],'mm/dd/yyyy')

But same result.

Any thoughts on this..?

Appreciate your reply on this.

Thank you.

ananda

1 ACCEPTED SOLUTION

Accepted Solutions

I've tried below code and it worked. It's not the Upper Case vs Lower Case.


Text(DataCardValue13.SelectedDate, "[$-en-US]yyyy-mm-dd").

It's quite strange.

Thank you.

 

View solution in original post

6 REPLIES 6
haroldbk_msft
Community Support
Community Support

SharePoint Dates are usually formatted yyyy-MM-dd

Need to use uppper case M for month since lower case m is minutes

 

Tried

Text(DataCardValue13.SelectedDate,"[$-en-US]MM/DD/YYYY","en-US"),

Same error.

Thanks

try this 

Text(DataCardValue13.SelectedDate,"[$-en-US]yyyy-MM-dd","en-US"),

Using all caps is not right and it should be year month day for SharePoint dates

I've tried below code and it worked. It's not the Upper Case vs Lower Case.


Text(DataCardValue13.SelectedDate, "[$-en-US]yyyy-mm-dd").

It's quite strange.

Thank you.

 

View solution in original post

JacquelineRiiv
Regular Visitor

Yo tengo el mismpo problema y con la solucion que comentas no se ha solucionado

 

Les comaprto el error que me aparece

 

JacquelineRiiv_0-1610394149266.png

This worked for me, and note that my SharePoint time format is UK (dd/mm/yyyy), but once passed from PowerApps > Power Automate > SharePoint List the date was automatically converted from UK to US.

Helpful resources

Announcements
User Group Leader Meeting January 768x460.png

Calling all User Group Leaders!

Don't miss the User Group Leader meetings on January, 24th & 25th, 2022.

Community Connections 768x460.jpg

Community & How To Videos

Check out the new Power Platform Community Connections gallery!

Top Solution Authors
Top Kudoed Authors
Users online (1,622)