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!View all the Fabric Data Days sessions on demand. View schedule
Hello Microsoft Support Team,
I'm trying to apply conditional formatting to the Y-axis labels of a clustered bar chart in Power BI using a DAX measure like this:
ColorMeasure =
VAR _selected = SELECTEDVALUE('ParameterTable'[Parameter])
RETURN
IF(
SELECTEDVALUE('MainTable'[Category]) = _selected,
"#505050",
"#FFFFFF"
)
The chart uses MainTable[Category] on the Y-axis. A slicer uses ParameterTable[Parameter]. These tables are not related because I want all categories visible, but only the selected one to appear gray.
The issue is that the measure doesn't respond to slicer selection. It seems Power BI needs a relationship for the slicer to influence the measure, even though I only want to reference the selected value.
Can conditional formatting of axis labels respond to slicers without relationships? If not, is there a workaround like TREATAS? Is this a known limitation or by design?
Thanks for your help.
Solved! Go to Solution.
Hi @yerketai,
Thank you for reaching out to Microsoft Fabric Community.
Thank you @FarhanJeelani for the prompt response.
Power BI currently does not support per tick conditional formatting of axis labels. Axis conditional formatting evaluates as a single value for the visual, so you can set one dynamic color for the whole axis but cannot color individual Y-axis labels based on slicer selection.
The best approach is to color the bars or data labels instead of the axis labels, this evaluates per category and will respond to your disconnected slicer.
Thanks and regards,
Anjan Kumar Chippa
Hi @yerketai ,
No, axis label formatting won’t respond to a slicer from a disconnected table. DAX in conditional formatting uses the visual’s filter context, which isn’t activated without a relationship.
Workarounds:
Add a bridge table that links ParameterTable[Parameter] to MainTable category keys, then use TREATAS/RELATE to push the slicer filter to the axis context.
Create a measure that propagates the selected parameter via that bridge so the axis colors update.
In short: either create a bridge table (or proper relationship) or use TREATAS to propagate the slicer filter; this is a known limitation of axis formatting without relationships.
A compact example skeleton (adjust to your schema):
Bridge table:
ParameterCategoryBridge(Parameter, CategoryKey)
Relationships:
ParameterTable[Parameter] 1..* to ParameterCategoryBridge[Parameter] (or many-to-one as appropriate)
ParameterCategoryBridge[CategoryKey] 1..1 to MainTable[CategoryKey]
Measure:
ColorMeasure = VAR _selected = SELECTEDVALUE( ParameterTable[Parameter] ) VAR _isGray = CALCULATE( IF( ISBLANK(_selected), 0, 1 ), TREATAS( VALUES( ParameterTable[Parameter] ), ParameterCategoryBridge[Parameter] ), TREATAS( VALUES( MainTable[CategoryKey] ), ParameterCategoryBridge[CategoryKey] ) ) RETURN IF( _isGray = 1, "#505050", "#FFFFFF" )
Please mark this post as solution if it helps you. Appreciate Kudos.
Hi, thanks again for your response!
I tried both the bridge table and TREATAS workaround as you suggested, but unfortunately, I'm still not seeing any change in the conditional formatting on the Y-axis labels when selecting a value from the slicer. The color does not update based on the slicer selection.
Could you please double-check the logic or possibly provide a working sample .pbix file or mock-up that demonstrates this functionality?
Just to recap:
I want all categories to always remain visible on the Y-axis.
I want only the selected category (from a slicer tied to a disconnected ParameterTable) to appear in gray (#505050), and the rest in white.
No relationship exists between the slicer table and the main table.
If there's any tweak I'm missing or an alternative method you can demonstrate, it would be really helpful.
Thanks again for your support!
Hi @yerketai,
Thank you for reaching out to Microsoft Fabric Community.
Thank you @FarhanJeelani for the prompt response.
Power BI currently does not support per tick conditional formatting of axis labels. Axis conditional formatting evaluates as a single value for the visual, so you can set one dynamic color for the whole axis but cannot color individual Y-axis labels based on slicer selection.
The best approach is to color the bars or data labels instead of the axis labels, this evaluates per category and will respond to your disconnected slicer.
Thanks and regards,
Anjan Kumar Chippa
Hi @yerketai,
As we haven’t heard back from you, we wanted to kindly follow up to check if the solution I have provided for the issue worked? or let us know if you need any further assistance.
Thanks and regards,
Anjan Kumar Chippa
Hi @yerketai,
We wanted to kindly follow up to check if the solution I have provided for the issue worked? or let us know if you need any further assistance.
Thanks and regards,
Anjan Kumar Chippa
thank you but both approaches did not work
could you please recheck and send me the testing dashboard with working logic
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!