cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
koneill2020
Helper I
Helper I

Formatting Date using Select Value

All,

In the below - I am trying to use the formatDate command to show the dates formatted in the general format (example: 3/29/2021 1:45 PM) as when I have the SharePoint fields Start Date and End Date in the Select  it shows them formatted as such for example: 2022-03-29T17:00:00Z and I'm trying to format them nicely - therefore what is the syntax for this that is best to accomplish what I'm trying to do: 

koneill2020_0-1648690108238.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
Mira_Ghaly
Dual Super User II
Dual Super User II

@koneill2020 

This is the expression that you should be using, replace the format with whatever your format is and start date with the correct column names in sharepoint.

if(equals(item()?['StartDate'],null),'',formatDateTime(item()?['StartDate'],'dd-MM-yyyy'))

 

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

View solution in original post

2 REPLIES 2
Mira_Ghaly
Dual Super User II
Dual Super User II

@koneill2020 

This is the expression that you should be using, replace the format with whatever your format is and start date with the correct column names in sharepoint.

if(equals(item()?['StartDate'],null),'',formatDateTime(item()?['StartDate'],'dd-MM-yyyy'))

 

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
koneill2020
Helper I
Helper I

@Mira_Ghaly Many thanks! These logic aspects like that - I always struggle with.

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

MPA Licensing.jpg

Ask your licensing questions at the Power Automate AMA!

Join Priya Kodukula and the licensing team, super users and MVPs to find answers to your questions on Power Automate licensing.

Users online (1,958)