Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreNext up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now
I have a table which shows the number of car crashes for each car within with 3 columns - HIgh, Medium, low.
I want to add conditional formatting to each cell. The conditions are for the background color to changes depending on the numerical value in the cell. But these thresholds CANT BE the SAME for each column.
Example:
High Column: 0 to 10 = Green Background ; 11 to 20 = Yellow Background ; 22 to 30+ = Red Background
Medium Column: 0 to 20 = Green Background ; 21 to 49 = Yellow Background ; 50+ = red background
Is there any way to apply conditional formatting to each column rather than the entire table?
thanks guys
Solved! Go to Solution.
Hi @Anonymous ,
Please refer to my .pbix file.
Best regards,
Lionel Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
Try to use the feature.
Best regards,
Lionel Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Here is the visual :
notice how the columns are an option for conditional formatting? just the values for the table.
Hi there,
Thanks this is very helpful.
The issue is that the values are a measure, the columns are high,medium,low. these dont show up as options under the conditional formatting list.
Cheers
@Anonymous , You can create a color measure using switch and can use that in conditional formatting using 'Filed value option
Switch( True() ,
max(Table[high]) <=10 , "Green",
max(Table[high]) <=20 , "yellow",
"red"
)
Same way you can create other measures or combined measures.
refer for steps
https://radacad.com/dax-and-conditional-formatting-better-together-find-the-biggest-and-smallest-numbers-in-the-column
https://docs.microsoft.com/en-us/power-bi/desktop-conditional-table-formatting#color-by-color-values
Hi there,
Thank you for your help.
I'm sorry I dont fully understand the process as explained above. Could you provide more detail? What do i do once I have created a measure with the above DAX code?
Cheers
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 53 | |
| 45 | |
| 44 | |
| 20 | |
| 19 |
| User | Count |
|---|---|
| 73 | |
| 71 | |
| 34 | |
| 33 | |
| 31 |