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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
epang
Frequent Visitor

How to do conditional formatting

I have list of survey data for multiple organisations. 

 

THey have provided minium target, long term target and actual value. 

 

Eg company A Team A has a question about Staff satisfaction.  minimum is 60%, long term target is 65%. actual is  62%.

 

Achieve minimum will get a yellow rating, achieve long term target or above will get a green rating. not achieving minimum will get a red. 

 

I have 100 Teams and each have their own target. What is the easiest way to display the value in the traffic color format?

 

Thanks

3 REPLIES 3
SamInogic
Super User
Super User

Hi @epang ,

 

We have considered that the data table include below sample data,

SC1.png

You can create a column with DAX to define colour based on the conditions you mentioned for Actual value,


Color for Result = IF('TargetData'[actual ] < 'TargetData'[Minimum Target], "Red", IF('TargetData'[actual ] >= 'TargetData'[Minimum Target] && 'TargetData'[actual ] < 'TargetData'[long term target], "Yellow", IF('TargetData'[actual ] >= 'TargetData'[long term target],"Green")))

Based on this colour you can show traffic signal icons in column of table, for this add the “Color if Result” column and apply conditional formatting.

 

Please refer to the below screenshot for the same.

SC2.png

 

This will result as follows,

SC3.png

 

Thanks!

 

Inogic Professional Services Division

Power Platform and Microsoft Dynamics 365 CRM Development – All under one roof!

Drop an email at crm@inogic.com

Services:  http://www.inogic.com/services/

Power Platform/Dynamics 365 CRM Tips and Tricks:  http://www.inogic.com/blog/

Inogic Professional Services: Power Platform/Dynamics 365 CRM
An expert technical extension for your techno-functional business needs
Service: https://www.inogic.com/services/
Tips and Tricks: https://www.inogic.com/blog/

here is the dax measure I have created. 

 

Color = if('11 Staff Satisfaction'[Value]>= '11 Staff Satisfaction'[3 Satisfaction Targets.Long Term Target], "Green", if('11 Staff Satisfaction'[Value] >= '11 Staff Satisfaction'[3 Satisfaction Targets.Minimum Target],"Orange", if('11 Staff Satisfaction'[Value] <'11 Staff Satisfaction'[3 Satisfaction Targets.Minimum Target], "Red")))
 
However, I cannot apply this to callout value coloring scheme. Any clue?
 
epang_0-1691710670479.png

 

Ritaf1983
Super User
Super User

Hi @epang 

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 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.

Top Solution Authors