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 other measures

Hi everyone,

 

I am looking to conditional format a card dependent on another different measure and have that conditional formatting change dependent on the slicers.

 

My slicer is for the teams

Team A's Target - 700k

Team A's Closed Business - 600k

Team B's Target - 650k

Team B's Closed Business - 660k

 

Ideally this is what I want: 

If I select team A, I will see the two cards like so:

700         |       600

Target    Actual

 

But if I change my view to team B, I will see:

650         |       660

Target    Actual

 

Is this possible? I can only seem to be able to do this by hardcoding the values, which wouldn't work in this situation.

 

Thanks!

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous ,

I went ahead and created a little data set in excel:

demo pic.png

 

 

 

 

I created a slicer for team

 

Then I created a measure:

Conditonal Format Flag = if(max(Sheet1[Target])>max(Sheet1[COB]),1,-1)

Then going under the card visualization, select > Format>Data Label>the little elipses by Color>Condtional Formatting.
 
From there
Format by: Rules
Based on field: Condtional Format Flag
 
Rules:
If values is 1 then Red (under target)
If value is -1 then Green (on or over target)
 
 
Hope this helps!
 
Caleb Foster

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous ,

I went ahead and created a little data set in excel:

demo pic.png

 

 

 

 

I created a slicer for team

 

Then I created a measure:

Conditonal Format Flag = if(max(Sheet1[Target])>max(Sheet1[COB]),1,-1)

Then going under the card visualization, select > Format>Data Label>the little elipses by Color>Condtional Formatting.
 
From there
Format by: Rules
Based on field: Condtional Format Flag
 
Rules:
If values is 1 then Red (under target)
If value is -1 then Green (on or over target)
 
 
Hope this helps!
 
Caleb Foster
Anonymous
Not applicable

It worked! Thanks for the help 🙂 

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