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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Conditional formatting based on % of another column

DeeMeza_0-1630424282376.png

 I need the EAC column to change colors (stoplight) as follows:

green=EAC is 90% or less of the Approved Budget

yellow=EAC is 100% or less of the Approved Budget

red=EAC is 100% or greater of the Approved Budget.

 

I can't seem to get conditional formatting right, nor can I figure out the Dax for this.  The EAC column is a measure (if that makes a difference).  Here is the conditional formatting that shows the colors as above.  As you can see, it isn't behaving as I'd like.  I THINK it's partly because there is an overlap...

DeeMeza_1-1630424541811.png

Any suggestions would be appreciated!

 

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Okay, so I finally figured it out.  I changed the percentages to 'number' on the dropdown and added the decimal.  That, in it's self still wasn't working correctly.  I discovered that you were partially correct in that, but not 100%.  What works (the way I need it to) is to change the first value ("is" statement) to percent.  Now, the icons are the correct color according to my needs.  I appreciate your help in getting me there!

DeeMeza_0-1630624801948.png

 

View solution in original post

12 REPLIES 12
Anonymous
Not applicable

I found a work around that almost works.  Can someone tell me WHY IN THE WORLD the conditional formatting isn't working?  I've tried it several different ways and it acts like it's not reading the % correctly.  The ones that are currently yellow should be red and the one with no icon should be yellow.  Is it because that What% column is a measure?

DeeMeza_0-1630600057612.png

 

change the percent values into decimal

you should change the percentage value into decimal like 15% into .15 

Anonymous
Not applicable

Thank you for the suggestion.  I tried it.  The result is blanks where the icons should be. 😞

DeeMeza_0-1630600657428.png

 

Is what% is a measure? if it is measure please share a dax

Anonymous
Not applicable

 

What% = DIVIDE(
('Measures (2)'[EAC]),
Sum(Budget[Approved Budget]))

If your measure is in percentage format it won't work as it works only on integer values

Anonymous
Not applicable

I don't understand.  I need the %...and the conditional formatting has a percent option (as apposed to number).  If it has the option of percent, why use integers?  

 

Note: I did change the measure to decimal number, then whole number AND changed the conditional formatting to number.  My data then shows up incorrectly, and the icons are still not correct.

123.PNG

I have done like this , you can get help from this

Anonymous
Not applicable

The additional column won't work for my needs.  I need the EAC column to change color.  From the link you sent, it would appear that Power BI isn't capable of doing what I'm wanting.  Is this correct?

ziyabikram96
Helper V
Helper V
Anonymous
Not applicable

Okay, so I finally figured it out.  I changed the percentages to 'number' on the dropdown and added the decimal.  That, in it's self still wasn't working correctly.  I discovered that you were partially correct in that, but not 100%.  What works (the way I need it to) is to change the first value ("is" statement) to percent.  Now, the icons are the correct color according to my needs.  I appreciate your help in getting me there!

DeeMeza_0-1630624801948.png

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors