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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
pminnov
Helper I
Helper I

create space between value and % symbol

Hi, I've created two PBI reports - one in English and one in French. In the French report, I replaced all English text with French and when I published the report and added '&language=fr-ca' to the end of the report link, decimal value separators changed from periods to commas which was correct. What didn't change however is that for column charts with data labels and y-axis values containing percent values, a space was not added between the value and the % sign. I've tried different approaches but I haven't been able to solve it. Any help would be greatly appreciated. 

1 ACCEPTED SOLUTION

Thanks solution from @danextian 

Hi, @pminnov 

Based on your description, if you want to add a space between the value and % in the percentage of the data label, you can do this:

First, I created a measure to find my percentage of sales and put it into the Stacked column chart visual. There is no space between the percentage and the % symbol:

vjianpengmsft_0-1713512341397.png

vjianpengmsft_1-1713512475597.png

I used the following DAX to create a percentage of text type spaces:

Have space percentage = FORMAT([Measure of Percentage],"0.00 %")

In this case, you need to use the measure of this text type in Format>>Data labels>>Value:

vjianpengmsft_2-1713512619935.png

vjianpengmsft_3-1713512669588.png

At this point, it has been discovered that there is already a space between the value and the percentage:

vjianpengmsft_4-1713512737325.png

I've provided the PBIX file used this time below.

 

 

 

How to Get Your Question Answered Quickly

If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .

Best Regards

Jianpeng Li

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

 

 

 

View solution in original post

3 REPLIES 3
danextian
Super User
Super User

Hi @pminnov ,

 

Beginning spaces are treated in the visuals like they aren't there. One workaround is to use UNICHAR (127 ) instead of a " ". https://stackoverflow.com/questions/47324449/adding-whitespace-in-a-dax-expression-for-display-in-pb... 










Did I answer your question? Mark my post as a solution!


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

Wouldn't this change the measure to text (and therefore unable to be displayed in a chart)? The % symbol needs to be displayed for data labels in column charts. 

Thanks solution from @danextian 

Hi, @pminnov 

Based on your description, if you want to add a space between the value and % in the percentage of the data label, you can do this:

First, I created a measure to find my percentage of sales and put it into the Stacked column chart visual. There is no space between the percentage and the % symbol:

vjianpengmsft_0-1713512341397.png

vjianpengmsft_1-1713512475597.png

I used the following DAX to create a percentage of text type spaces:

Have space percentage = FORMAT([Measure of Percentage],"0.00 %")

In this case, you need to use the measure of this text type in Format>>Data labels>>Value:

vjianpengmsft_2-1713512619935.png

vjianpengmsft_3-1713512669588.png

At this point, it has been discovered that there is already a space between the value and the percentage:

vjianpengmsft_4-1713512737325.png

I've provided the PBIX file used this time below.

 

 

 

How to Get Your Question Answered Quickly

If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .

Best Regards

Jianpeng Li

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

 

 

 

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.