This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
I am trying to create a measure that I can then apply as a rule for conditional formatting.
I would like to achieve the following:
Highlight to be applied if:
Any assistance is appreciated.
Thank you in advance.
Solved! Go to Solution.
Try this measure
Conditional Formatting Measure =
SWITCH(
TRUE(),
[Baseline Value] < 100000 && ABS([Variance%]) >= 100, 1,
[Baseline Value] >= 100001 && [Baseline Value] <= 300000 && ABS([Variance%]) >= 50, 1,
[Baseline Value] >= 300001 && [Baseline Value] <= 500000 && ABS([Variance%]) >= 25, 1,
[Baseline Value] > 500000 && ABS([Variance%]) >= 20, 1,
0
)
, Create a measure for this
This measure will return 1 if any of the conditions are met and 0 otherwise
Once you have created the measure, you can use it to apply conditional formatting to your table or matrix visual.
Select the table or matrix visual where you want to apply the conditional formatting.
Go to the Format pane.
Expand the Conditional formatting section.
Choose the field you want to format (e.g., [Baseline Value] or [Variance%]).
Click on Advanced controls.
In the Conditional formatting dialog, select Format by as Field value.
In the Based on field dropdown, select the measure you created (ConditionalFormattingMeasure).
Set the formatting options (e.g., font color, background color) based on the value of the measure.
Set Formatting Rules:
If the measure returns 1, apply the desired formatting (e.g., highlight the cell).
If the measure returns 0, no formatting is applied.
Proud to be a Super User! |
|
Thank you both, both of these measures work, with one exception.
Instead of 100 / 50 / 25 / 20, I changed the measure to 1 / 00.5 / 0.25 / 0.2 and both work perfectly.
Appreciate you both taking the time to respond.
, Create a measure for this
This measure will return 1 if any of the conditions are met and 0 otherwise
Once you have created the measure, you can use it to apply conditional formatting to your table or matrix visual.
Select the table or matrix visual where you want to apply the conditional formatting.
Go to the Format pane.
Expand the Conditional formatting section.
Choose the field you want to format (e.g., [Baseline Value] or [Variance%]).
Click on Advanced controls.
In the Conditional formatting dialog, select Format by as Field value.
In the Based on field dropdown, select the measure you created (ConditionalFormattingMeasure).
Set the formatting options (e.g., font color, background color) based on the value of the measure.
Set Formatting Rules:
If the measure returns 1, apply the desired formatting (e.g., highlight the cell).
If the measure returns 0, no formatting is applied.
Proud to be a Super User! |
|
Try this measure
Conditional Formatting Measure =
SWITCH(
TRUE(),
[Baseline Value] < 100000 && ABS([Variance%]) >= 100, 1,
[Baseline Value] >= 100001 && [Baseline Value] <= 300000 && ABS([Variance%]) >= 50, 1,
[Baseline Value] >= 300001 && [Baseline Value] <= 500000 && ABS([Variance%]) >= 25, 1,
[Baseline Value] > 500000 && ABS([Variance%]) >= 20, 1,
0
)
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 30 | |
| 24 | |
| 23 | |
| 17 | |
| 15 |
| User | Count |
|---|---|
| 61 | |
| 36 | |
| 29 | |
| 22 | |
| 21 |