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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
sdg1393
Frequent Visitor

How to show text on bar graph

Hi,

 

I have a simple bar chart that shows % value (numerator / denominator) , now the requirement is to show numerator and denominator value along with % value ( not as tooltip) on the bar itself  - for example - 50% (10/20) instead of 50% . Since % field is number value so I can't have text in the bar chart.

 

Is there any way to show it [50% (10/20)]using some custom visuals like deneb or any other way? I don't have any idea about deneb so looking for an spossible solution for this requirement.

 

please share your ideas if you came accross this situation earlier.

 

Thanks

1 ACCEPTED SOLUTION
vicky_
Super User
Super User

The more recent versions of powerBI have custom labels, so you can format your own text for graphs and still use the out-of-box visuals. I would create a measure like:

Label = FORMAT(DIVIDE([numerator], [denominator]), "00%") & " " & [numerator] & " " & [denominator]

and use that, or you can experiment with the dynamic formatting options for measures.

Check out the following:
https://www.sqlbi.com/articles/introducing-dynamic-format-strings-for-dax-measures/

https://powerbi.microsoft.com/en-gb/blog/power-bi-may-2023-feature-summary/#post-23312-_Toc134425713

 

View solution in original post

1 REPLY 1
vicky_
Super User
Super User

The more recent versions of powerBI have custom labels, so you can format your own text for graphs and still use the out-of-box visuals. I would create a measure like:

Label = FORMAT(DIVIDE([numerator], [denominator]), "00%") & " " & [numerator] & " " & [denominator]

and use that, or you can experiment with the dynamic formatting options for measures.

Check out the following:
https://www.sqlbi.com/articles/introducing-dynamic-format-strings-for-dax-measures/

https://powerbi.microsoft.com/en-gb/blog/power-bi-may-2023-feature-summary/#post-23312-_Toc134425713

 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.

Top Solution Authors