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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
Anonymous
Not applicable

Formatting background color in a table based on the condition from measure

Hi everyone, I have got a table that has two columns user and revenue%. User information comes from one table and revenue% comes from the measure. I want to change the background color for each user based on conditions. I tried using conditional formatting but it just allowed me for the highest and minimum for everyone in the table. I want to change the color for each user based on certain conditions for them. I have attached one photo here for detailed info. Thank youque.jpg 

7 REPLIES 7
wdx223_Daniel
Super User
Super User

wdx223_Daniel_0-1611536465079.png

you need a measure to define which color to apply

 

Anonymous
Not applicable

Hi super user II, can you please show the snapshot of the colors table. Just confused about what to enter into those columns of the colors table. Thank you.

wdx223_Daniel_1-1611539695162.png

 

Anonymous
Not applicable

Sorry for giving you trouble. Just got one issue. Since my revenue% is a calculated measure I couldn't give it inside the MAX function. The following error came:
The MAX function only accepts a column reference as the argument number 1.
What would be the solution for this?

adding a var

var _revenue=[Revenue%]

then use it to replace max()

lbendlin
Super User
Super User

Please provide sample data in usable format (not as a picture) , and show the expected outcome.

Anonymous
Not applicable

The thing is like the user name comes from one table that has so many columns. And revenue is the calculated measure that takes several column values from different tables.  How can I provide sample data for measure? 

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.