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
seancearnaigh
Frequent Visitor

Auto change a card background colour depending on text within

Hi Folks,

 

From a Project Management perspective, i want to show the rag status of a project as red, green, amber. Now we have more than one project on the go so as opposed to manually going in and changing the background coulour of all projects, is there any custom visual that can check if status = GREEN, change background colour to green, same for Amber / Red ??

 

I know there is one based on values (Card with states) but not text from what i have seen so far??

 

Any thoughts?

1 ACCEPTED SOLUTION
Seth_C_Bauer
Community Champion
Community Champion

@seancearnaigh You can do this with a combination of DAX function and layering. @SqlJason wrote up a good blog around this awhile ago. You can check it out here


Looking for more Power BI tips, tricks & tools? Check out PowerBI.tips the site I co-own with Mike Carlo. Also, if you are near SE WI? Join our PUG Milwaukee Brew City PUG

View solution in original post

5 REPLIES 5
Seth_C_Bauer
Community Champion
Community Champion

@seancearnaigh You can do this with a combination of DAX function and layering. @SqlJason wrote up a good blog around this awhile ago. You can check it out here


Looking for more Power BI tips, tricks & tools? Check out PowerBI.tips the site I co-own with Mike Carlo. Also, if you are near SE WI? Join our PUG Milwaukee Brew City PUG

thank you for that info - really appreciate it

Anonymous
Not applicable

@seancearnaigh : Where you able to achieve this? If yes, could you please shed some light? 

Yes - We had a  field called rag status which contained Red - Amber - Green. I created another numeric field to correspond to these -> 0 -1 - 2

 

Then go into your report - edit it - Go into Conditional Format - select the field you want to colour to appear on - Turn on Background Colour and hit Advanced Controls - Format by Rules - select the new field with the numeric values (0-1-2) within the 'Based on Field' drop down - Then just add your rules accordingly.

 

Note, there may be an easier way to do above but it worked for me!

Anonymous
Not applicable

Hi @seancearnaigh : What you are saying can be achieve by using a table not a card, right? 

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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