Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
BZ_AF
Frequent Visitor

How to do Number Formatting for Visual Calculations

Is there a way to do a number formatting for visual calculations?

 

It seems to follow the original measure, but when I do a divide to get a % of Total I want to present a percentage. Currently that doesn't seem possible. See below example:

  • I have two measures,
    • [Sales Amount] formatted as currency
    • [Sales Amount (Fmt % 1dp)] with same amount, formatted as percentage.
    • Visual Calculations:
      • Cumulative Sales = RUNNINGSUM([Sales Amount])
      • % of Final Number = DIVIDE(RUNNINGSUM([Sales Amount (Fmt % 1dp)], ROWS), COLLAPSEALL([Sales Amount (Fmt % 1dp)], ROWS))

 

As you can see the tooltips no longer carry the original formatting. Is there a way to customize the formatting? FORMAT does not work here as it returns a text value which cannot be displayed on the chart. 

 

vizcalc.PNG

9 REPLIES 9
grnelson1797
Regular Visitor

I was able to get this to work by formatting the original data label as a percentage and then adding the calculation.  You have to add the custom format before inserting the calculation.

 

grnelson1797_0-1714076570274.png

 

Thanks for the reply. We have tested it and it works for displaying on the line chart, but it does not affect the tooltip. The main objective is to have the tooltip display with the number formatting we need so this is not resolved yet.

Anonymous
Not applicable

Hi  @BZ_AF 

 

@Idrissshatila , thanks for your concern about this case.

 

Do you want the points on each line to show their respective values? I did the following test using sample data, hope it helps.

 

I created two measurements and a visual calculation just to reproduce the steps you did.

 

two measures:

 

sum = CALCULATE(SUM(financials[Profit]), ALLEXCEPT(financials, financials[Country]))
total = CALCULATE(SUM(financials[Profit]), ALL(financials)) 

 

 

Visual Calculations:

vxuxinyimsft_0-1714024849054.png

 

Then I turned on the Data labels option.

vxuxinyimsft_1-1714024948032.png

 

Result:

vxuxinyimsft_2-1714025069508.png

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

I think you missed the point of the question. You haven't shown how to format the number as a percentage.

Anonymous
Not applicable

Hi @BZ_AF 

 

After my testing, Tooltip is not able to customize the format.

 

The following ways are for your reference.

 

vxuxinyimsft_0-1714032951711.png

 

vxuxinyimsft_1-1714032968358.png

 

vxuxinyimsft_2-1714032985906.png

 

Result:

vxuxinyimsft_3-1714033050731.png

 

Best Regards,
Yulia Xu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Idrissshatila
Super User
Super User

Hello @BZ_AF ,

 

check if this video helps https://youtu.be/59JU4JO-9HU?si=N-tydy8DK8hfGLIp

 



Did I answer your question? Mark my post as a solution! Appreciate your Kudos
Follow me on LinkedIn linkedIn
Vote for my Community Mobile App Idea

Proud to be a Super User!




It does not help. It uses FORMAT to do the formatting on a table which returns a text. It will make the line disappear on the chart.

@BZ_AF ,

 

you could check this thread, as many people shared there thoughts here 
https://community.fabric.microsoft.com/t5/Desktop/Share-your-thoughts-on-visual-calculations-preview...

 



Did I answer your question? Mark my post as a solution! Appreciate your Kudos
Follow me on LinkedIn linkedIn
Vote for my Community Mobile App Idea

Proud to be a Super User!




Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.