Skip to main content

Notifications

Community site session details

Community site session details

Session Id : QZ2g+Oz2UTKz2OohnsId0P
Power Automate - Building Flows
Unanswered

Format Currency in HTML Table

Like (0) ShareShare
ReportReport
Posted on 15 Jul 2019 16:50:29 by 97

Hi,

I have a flow that creates a HTML table from a sharepoint list then adds it to an email. The flow works fine and all the data is there but the currency colums display such as 30.0000000000000 with no ÂŁ sign. 

 

Can anyone advise me how this would be achieved. 

 

Regards,

Chris

 

 

1.JPGflow.JPG

  • huntjk Profile Picture
    2 on 08 Apr 2024 at 16:51:05
    Re: Format Currency in HTML Table

    I am using the formula posted in a solution as follows:

     

    if(contains(item()?['NAME of FIELD'],'.00'),concat('$',string(float(item()?['NAME of FIELD'])),'.00'),concat('$',string(float(item()?['NAME of FIELD']))))

     

    I would like for it to include 2 decimal places (the original spreadsheet has these in currency form) ---reading:

     

    $24.00

    not $24

     

    Is there a small tweek in the code??

  • v-yamao-msft Profile Picture
    on 29 Jul 2019 at 08:24:54
    Re: Format Currency in HTML Table

    Hi @Barber_Chris ,

     

    You may need to modify the function likes below:

    if(contains(item()?['cis'],'.00'),concat('ÂŁ',string(float(item()?['cis'])),'.00'),concat('ÂŁ',string(float(item()?['cis'])))

    However, if you want the end of the number always to be 2, you may need to add more conditions in the flow to check if it has two decimals, if not, format it.

     

    Best regards,

    Mabel   

           

  • Barber_Chris Profile Picture
    97 on 23 Jul 2019 at 09:55:40
    Re: Format Currency in HTML Table

    Hi @v-yamao-msft ,

    Im getting the same outcome. The ÂŁ sign is at the end of the number and its not always 2 decimal places. 

     

    1.JPG

  • v-yamao-msft Profile Picture
    on 23 Jul 2019 at 09:11:38
    Re: Format Currency in HTML Table

    Hi @Barber_Chris ,

     

    Please try with the following code:

     

    if(contains(item()?['cis'],'.00'),concat(string(float(item()?['cis'])),'.00ÂŁ'),concat(string(float(item()?['cis'])),'ÂŁ'))
    
    

    1.PNG

     

     

    Best regards,

    Mabel  

     

  • Barber_Chris Profile Picture
    97 on 19 Jul 2019 at 08:38:38
    Re: Format Currency in HTML Table

    Hi @v-yamao-msft 

    Thanks for ocming back to me so in looking for it to display like this ÂŁ1000.00

     

    Regards,

    Chris

  • v-yamao-msft Profile Picture
    on 19 Jul 2019 at 08:28:48
    Re: Format Currency in HTML Table

    Hi @Barber_Chris ,

     

    What’s your expected result? Could you show me an example?

     

    Actually, I am getting the same result with you for the CIS column.

     

    However, Flow doesn’t have the same Text function to format a number or a date/time value.

     

    Let me see if I could help figure out it for your scenario.

     

    Best regards,

    Mabel          

     

  • Barber_Chris Profile Picture
    97 on 16 Jul 2019 at 08:46:22
    Re: Format Currency in HTML Table

    Hi Mabel,

    Im getting somewhere following your post thanks. 

     

    So I tried as you said with the following expression:- 

     

    concat(string(float(item()?['CIS_x0020_on_x0020_Labour'])),'ÂŁ')

     

     

    1.JPGAnd not its displaying like this...

     

  • v-yamao-msft Profile Picture
    on 16 Jul 2019 at 08:35:01
    Re: Format Currency in HTML Table

    Hi @Barber_Chris ,

     

    I assume that the column CIS is a calculated column, I have figured out the following workaround for your scenario, please check it for a reference.

     

    Input the following code in the value field of CIS field:

    concat(string(float(item()?['cis'])),'ÂŁ')

    1.PNG

     

    Best regards,

    Mabel  

     

  • yashag2255 Profile Picture
    24,442 Super User 2024 Season 1 on 15 Jul 2019 at 17:53:58
    Re: Format Currency in HTML Table

    Hi @Barber_Chris 

     

    You can initialise a variable and then pass the currency value in that and then use an expression to trim the decimals. Please see the solved thread below for the expression: 

    https://powerusers.microsoft.com/t5/Building-Flows/decimal-place/td-p/50303

    Rounding currency/ decimals is not available as direct action or function in flow currenlty and you can upvote this idea here: 

    https://powerusers.microsoft.com/t5/Flow-Ideas/Currency-and-decimal-format-in-Microsoft-Flows/idi-p/38723

     

    Hope this Helps!

    If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

  • Barber_Chris Profile Picture
    97 on 15 Jul 2019 at 16:52:23
    Re: Format Currency in HTML Table

    I forgot to mention im looking to reduce the number of decimal places to 2

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,702 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,015 Most Valuable Professional

Leaderboard
Loading started