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

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to update date and...
Power Automate
Unanswered

How to update date and other calculated field in Flow, sent email action to reflect it correctly?

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi, 

 

I have a flow setup that runs each time an entry is submitted based on a list form. its an approval workflow with basic send an email and update item action with some conditions.

 

I have a calculated date field and a calculated number field that is included in the body of the Send an email action. For some reason the calculated date field shows value with time zone and the Calculated number field shows many irrelevant zeros after the decimal point. Please see below screenshot of the email sample.

 

Hello User,

 

Your Request has  been Approved! You should use your days credit 1.00000000000000 before 2018-10-12T07:00:00Z.

 

Best Regards,

Manager.

 

The Days credit value should be presented as 1.0 and date field should exclude the time zone info. So it should appear as 1.0 and 2018-10-12 (if this can be changed to 10/12/2018(mm-dd-yyyy), that would be ideal). Can someone please help me with a solution for this? Thanks in advance. 

Categories:
I have the same question (0)
  • v-yamao-msft Profile Picture
    Microsoft Employee on at

    Hi @Anonymous,

     

    It seems that you want to format both the types of Date time and Number.

     

    Yes, we could format Date time using the function formatDateTime, however, currently there is no function can be used to format Number.

     

    About the Date time, you could use the following function:

    formatDateTime(triggerBody()?['CalculatedDate'],'MM/dd/yyyy HH:mm:ss')

     

    About the Number, if you want to format the type of Number, please submit a request on Flow Ideas Forum:

    https://powerusers.microsoft.com/t5/Flow-Ideas/idb-p/FlowIdeas

     

    A screenshot for your reference:

    1.PNG

     

     

    Best regards,

    Mabel Mao

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Mabel,

     

    Thanks a lot for providing a solution, I will give it a try to make the change for the date field. Is there no other way to fix the Calculate dnumber field, I mean it is important to see these two values in the email. Any other suggestions?

  • ScottShearer Profile Picture
    25,280 Most Valuable Professional on at

    As a work around for the number issue, try the following:

    1) use the div expression

    2) Use your existing calcuation as the dividend (top number)

    3) Use 1 as the divisor (bottom number)

     

    I did some limited testing and this technique seems to work - you won't get back a decimal, you'll get back a whole number but hopefully that will work for you.

     

    Scott

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Scott,

     

    The calculated field assigns 0.5 as value to itself if certain date is populated in a date field. So there is no division in place.

  • ScottShearer Profile Picture
    25,280 Most Valuable Professional on at

    Didn't realize that.....

    But you also have access to the remainder via the Mod function.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi Scott,

     

    Here is how my calculated field's formula looks like:

    =(INT((WEEKDAY([Start Date]-1)+[End Date]-[Start Date])/7)*0.5)+(INT((WEEKDAY([Start Date]-7)+[End Date]-[Start Date])/7)*0.5)

     

    What shoudl i change in the above to solve the decimal points issue in the flow email body?

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
trice602 Profile Picture

trice602 224 Super User 2026 Season 1

#2
David_MA Profile Picture

David_MA 181 Super User 2026 Season 1

#3
Kalathiya Profile Picture

Kalathiya 97 Super User 2026 Season 1

Last 30 days Overall leaderboard