Forum Discussion
Conditional formatting on stacked column chart
- 10 months ago
The Power BI Desktop interface won't allow conditional formatting on any core stacked bar/column visuals when multiple measures or a legend field are included (as you've observed).
There is a "hack" which I've used in the past described in this post that involves editing the
visual.jsonfile within the PBIP format. I have tested this myself previously and it appears to work as expected, but it's not "officially" supported.
Hi, thanks for your reply. When you use just one measure and put status in the legend, you still don't have the option to apply conditional formatting.
Hi BBConsultancy,
You’re right, adding a legend to a stacked column or bar chart disables the conditional formatting (fx) option for data colors. This is a known limitation in Power BI visuals.
As a workaround, you can use a dynamic color measure or a field parameter to control colors based on the selected company.
Alternatively, custom visuals like Deneb or Charticulator allow color assignment through measures or expressions. If you want to use only native visuals, you can create a lookup table that maps each company to a specific color and reference it in your measure to dynamically set the Achieved color, while keeping To Go in light gray. This helps maintain visual consistency even without native conditional formatting when a legend is present.
Thank you and continue using Microsoft Fabric Community Forum.
- BBConsultancy9 months agoHelper I
Ideally I would use native visuals only. I am not sure your options would work though as they'd still require the conditional formatting option being enabled. I'll give the solution from OwenAuger a go. Thanks anyway!