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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
iuli
Regular Visitor

Conditional formatting for Total Label on stacked column chart

Hello, 

 

I used a measure to color the total label in red / green. For a matrix works ok, but not for total label. 

Capture.PNG

5 REPLIES 5
iuli
Regular Visitor

the attached picture shows how the conditional rule is appyed using the above color measure

Capture2.PNG

Anonymous
Not applicable

Hi @iuli ,

Can I know that are the field Products_CY and Products_PY fact fields of the table or measures? If they are measures, could you please provide their formula? By the way, all of fields which apply on the stacked column chart visual are all from the same table? It is better if you can provide a simplified pbix file. Thank you.

Best Regards

Hello, 

 

Products_CY and Products_PY  are fact fields of the table , but I tested also with measures and had the same result. Please try to download the pbix file via this link : 

publicerep/test total label color.pbix at main · iulianalidia/publicerep (github.com)

 

Thank you !

iuli
Regular Visitor

Hi,

 

the measure is : 

color = SWITCH(TRUE(), SUM('Table'[Products_CY]) > SUM('Table'[Products_PY]), 1 , 0 ) // 1=red, 0=green
amitchandak
Super User
Super User

@iuli , can you share the color measure ?

 

refer, if needed

How to do conditional formatting by measure and apply it on pie? : https://youtu.be/RqBb5eBf_I4

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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
Top Kudoed Authors