Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi All,
How to change the format on the Y-axis (% vs value) on a bar graph at run time?
I have two tables [ Data Table, Filter Table]. I am creating a bar graph with X-axis as Name and Y-axis as Output. "Output" is the measure which is changing between Sum_KPI and PCT_KPI as per the filter selection from Filter table. the formula for Output function is mentioned below:
Ouput = SWITCH(
SELECTEDVALUE(Filter_Table[Filter]),
"Sum", [Sum_KPI],
"Percentage", [PCT_KPI]
)
Value on Y-axis is getting change as per the selections from filter however formate is not getting change from value to the percentage or vice versa.
Kindly refer attached PBIX file for more detail.
Kindly suggest how to change the format on the Y-Axis at run time.
Thank you.
Solved! Go to Solution.
Hi @Anonymous ,
I'm afraid this may can't be achieved in Power BI. The format of one measure can't be changed dynamically between Number and Percentage.
One workaround, for example:
1. Insert Blank buttons.
2. Fill the button text with "Sum" and "Percentage".
3. After create all visuals, Duplicate this report page ("Sum").
4. Replace [Sum_KPI] with [PCT_KPI] in visuals.
5. Set Action of "Percentage" button on "Sum" page.
6. Set Action of "Sum" button on "Percentage" page.
7. Hide page "Duplicate of Sum".
8. Test.
BTW, .pbix file attached.
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
I'm afraid this may can't be achieved in Power BI. The format of one measure can't be changed dynamically between Number and Percentage.
One workaround, for example:
1. Insert Blank buttons.
2. Fill the button text with "Sum" and "Percentage".
3. After create all visuals, Duplicate this report page ("Sum").
4. Replace [Sum_KPI] with [PCT_KPI] in visuals.
5. Set Action of "Percentage" button on "Sum" page.
6. Set Action of "Sum" button on "Percentage" page.
7. Hide page "Duplicate of Sum".
8. Test.
BTW, .pbix file attached.
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Not able to upload the PBIX file
Sample data would greatly help, most people share their PBIX using OneDrive, Box or other file sharing service.
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!