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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Decimal places for a n...
Power Automate
Answered

Decimal places for a number sent to email using Power Automate/Flow

(0) ShareShare
ReportReport
Posted on by

Hello,

 

First off, I am a total newbie with this kind of thing, I'm working on a simple menu ordering system based on an MS Form, Excel, 2 emails and a Sharepoint list which stores the final data.

 

So, the Customer completes the form, power automate gets the response details, adds a row into an Excel table, Excel calculates the order total which is then grabbed using Compose and passed to an e-mail.

1.png

 

2.png

After some faffing around I have it working except for one thing.... When I pass the order total figure to the e-mail which will be sent to the customer, the figure is being cut to one decimal place if it ends with a zero, for example 17.25 displays fine in the e-mail body, but 17.10 displays as 17.1.

 

3.png

 

How do I correct this and force 2 decimal places so that zeros are displayed? Am I missing something really obvious (probably)?

 

Thanks in advance for your responses

 

Categories:
I have the same question (0)
  • Verified answer
    Expiscornovus Profile Picture
    33,195 Most Valuable Professional on at

    Hi @Anonymous,

     

    You could use a formatnumber function. With this you specify the format you want.

     

    In your setup you could add this expression to the body:

     

     

    formatNumber(float(outputs('Compose')?['Amount Total (Ex VAT)']), '0,0.00')

     

     

  • Community Power Platform Member Profile Picture
    on at

    Hi Expiscornovus, thank you thank you, that worked! Fantastic!

  • Expiscornovus Profile Picture
    33,195 Most Valuable Professional on at

    Hi @Anonymous,

     

    Btw, if you want to go a step further you could even use a currency format, like C2. This format will use two decimals and include the currency symbol as well 😁

     

     

    formatNumber(float(outputs('Compose')?['Amount Total (Ex VAT)']), 'C2')

     

     

  • Community Power Platform Member Profile Picture
    on at

    Great I'll add that in, thanks again!

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard