web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Changing a date format
Power Automate
Answered

Changing a date format

(0) ShareShare
ReportReport
Posted on by 98

Hi Community!

 

I have this little issue to fix: 

I'm building a flow that fetches information from an automated email message. In this one we get a date and time in the format that follows:

bebo987_0-1683046138815.png

however we need to plit this into DD/MM/YYY and separately HH:MM:SS. 

how can i get to that result?

 

thank you for your help

Categories:
I have the same question (0)
  • Verified answer
    Nived_Nambiar Profile Picture
    18,136 Super User 2026 Season 1 on at

    Hi @bebo987 

     

    Try this approach 

     

    Nived_Nambiar_0-1683048728448.png

     

    expression : 

    replace(replace(replace(replace(outputs('date_and_time_to_text')?['body'],'["',''),'"]',''),'.',' '),decodeUriComponent('%27'),'')
     
    this is to cleanup unecessary characters from the text.
     
    Nived_Nambiar_1-1683048788029.png

     

    expression: 

    formatDateTime(trim(split(outputs('Compose'),'@')?[0]),'dd/MM/yyy')
     
    this is to obtain date in dd/MM/yyy format
     
    Nived_Nambiar_2-1683048825515.png

     

    expression: 

    formatDateTime(trim(split(outputs('Compose'),'@')?[1]),'HH:mm:ss')
     
     
    Result
    Nived_Nambiar_3-1683048864238.png

     

     

     

    Hope it helps

     

    Mark it as solution if it resolves your query !

     

  • bebo987 Profile Picture
    98 on at

    HI @Anonymous 

     

    IT WORKS FINE ALTHOUGH THE VALUE EXTRACTED IS INSERTED INTO A SHAREPOINT LIST BUT INSTEAD OF COMING OUT AS DD/MM/YYYY COMES AS MM/DD/YYYY WHICH IS WRONG.

     

    THE FORMULA IN POWER PLATFORM IS: 

    formatDAteTime(trim(split(outputs('Cleanup_date_and_time_to_text'),'@')?[0]),'dd/MM/yyy')
     
    AND I HAVE TRIED TO CHANGE FORMAT IN SHAREPOINT HOWEVER NO SUCCESS. DO YOU HAVE ANY IDEA WHY
  • Nived_Nambiar Profile Picture
    18,136 Super User 2026 Season 1 on at

    Hi @bebo987 

     

    In sharepoint, I think date is stored in format of MM/dd/yyyy, that is why you got date stored as MM/dd/yyyy under datetime column.

     

    May be use a text column and store the date there, it would preserve the dateformat as dd/MM/yyyy 🙂

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 103 Super User 2026 Season 1

#2
Haque Profile Picture

Haque 87

#3
trice602 Profile Picture

trice602 63 Super User 2026 Season 1

Last 30 days Overall leaderboard