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 Apps / Date Formatting betwee...
Power Apps
Unanswered

Date Formatting between Power App and Power Automate

(0) ShareShare
ReportReport
Posted on by 28

So I have a date picker in my App that I have formatted to a long date.  This info gets sent to a flow which then uses the data to populate an email subject line.  Problem is that it is long date in the app and short date when it gets to the email.  I am sure there is something I need to be doing to the flow, but everything else is perfect bar this one bit, so I am loathe to mess about with it too much?  I have tried different combinations of formats ie using date format in the Power Apps (V2) trigger but it doesn't seem to change - it always comes through as a short date.  Please be fairly descriptive in any answers as I am fairly new so don't always know where certain fields are etc.

B33bop_0-1708013275060.png

B33bop_1-1708013878685.png

B33bop_2-1708013904054.png

 

Categories:
I have the same question (0)
  • Gil0 Profile Picture
    128 on at

    Hi @B33bop ,

     

    In the Subject input, rather than adding direct output from the Power App trigger, add an expression such as:

    formatDateTime(triggerBody()?['body/Date'], 'dd MMMM, yyyy'

     

    If this information was useful for you, please accept it as a solution so that it can help others.

  • B33bop Profile Picture
    28 on at

    Apologies for not getting back to you sooner but the above took me down a rabbit hole unfortunately.  I assumed that you meant the expression to be added to the body of the email and

    ['body/Date']

     the below was the input from the app (which was named DateReqRcvd) so it was input into the subject line as

    formatDateTime(triggerBody()?['DateReqRcvd'], 'dd MMMM, yyyy'

    ?  Apologies that I am that new - I sometimes need it spelling out for me!) I tried numerous combos of the above but in various instances it didn't like the date format coming from Power Apps (at which point I was trying to convert it in Power apps to the ISO 8601 standard and it never seemed to transfer correctly for some reason) saying either it wasn't in the right date format etc.  I also tried changing the Input format to Date instead of Text which it was originally (you can see it in my original pic above).  As you can see I am a bit confused (but not through lack of trying!)  Are you able to provide any clarity or advice on this?

  • Gil0 Profile Picture
    128 on at

    @B33bop I would change the input from Power Apps back to Date and then run a Compose action with the expression to format the date back to long date. (I know it's pretty redundant but the connector seems to modify the date for some reason)

     

    The expression should look like this:

    formatDateTime(triggerBody()?['DateReqRcvd'], 'dd MMMM, yyyy')

    You can remove the comma if preferred.

     

    Here is an example of a flow I made for testing:

    Gil0_0-1708108508376.png

    When the flow runs successfully, the date should output as such:

    Gil0_1-1708108556527.png

     

     

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 483

#2
WarrenBelz Profile Picture

WarrenBelz 399 Most Valuable Professional

#3
11manish Profile Picture

11manish 327

Last 30 days Overall leaderboard