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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
johnoxy
New Member

Use slicer behaviour to change the label values of the x axis on a chart

Hi. Hoping someone can lead my in the right direction.

I have a fact table(Year, Region, Area, measure). I have a basic bar chart with the Region column on the x axis.

The Region is also a slicer for the chart and is multi select and has a bult in All member.

What i would like is to create a column that combines the Region and Area columns into one column that would derive its values based on what the user selects or doesn't select on the Region slicer. This 'combined' column would replace the Region column as the source of label on the x axis.

 

Rules:

If All is selected then show Region labels.

If All is not selected, ie, a region/s is selected in the slicer then show Area labels.

 

I understand there are bookmarks and sheet swapping but the user base is used to this behaviour with Tableau so i want to investigate.

Cheers

2 REPLIES 2
johnoxy
New Member

Hi, thanks for the reply

Region column below is the slicer for the chart.

 

YearRegionAreaMeasure
2023Region1Area11
2023Region1Area23
2023Region1Area33
2023Region1Area44
2023Region1Area54
2023Region2Area69
2023Region2Area73
2023Region2Area810
2023Region2Area94
2023Region2Area104
2023Region3Area111
2023Region3Area123
2023Region3Area135
2023Region3Area148
2023Region3Area154

 

When All regions are selected in the slicer i want the Region to be the x axis label like this example:

johnoxy_0-1710219062761.png

When a region or regions is selected i want the Area to be the x axis label like this example:

johnoxy_1-1710219120132.png

 

Thanks.

Ritaf1983
Super User
Super User

Hi @johnoxy 

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors