Don't miss your chance to take exam DP-600 or DP-700 on us!
Request nowLearn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hello,
I have 2 seperate bar charts with "Months", "Years" (2018-2021), and "Passengers Total". Similarly, the second bar chart has "Months", "Years" (2018-2021), and "Flights Total". I am trying to highlight the busiest months for each year (2018-2021) for "Passengers Total" and Flights Total" using a specific color (red). I have tried changing the colors by using every option available (Gradient, Rules, Field Value) and none of them work or even apply to my particulat data because each year has a different Max value so I can't say if Passengers Totals is <= to 75K then make the color red because it would apply it to all the years and some years the max value is 72K, some 66K, etc. Also, it won't even let me select the word "Max" it wants me to enter a numerical value. I've tried to create a seperate table laying out the Max months and their values per each year and plotting it that way but that doesn't work properly. Below is my current bar charts for both "Passengers Totals" and Flights Totals" and the new tables for each with the max month values per year.
Solved! Go to Solution.
@laser_beam , First of all you can not apply conditional formatting when you use measure. So what you need to do is take both Year and month on axis. then You need expand them as use concatenate label off and sort on axis(year - month), repeat steps if you do not get below
Post that create a measure . Assuming flight is the measure and you are using
Then create a color measure
Color =
var _max = calculate(maxx(Values('Date'[Month Year]), [flight ]), filter(allselected('Date') , 'Date'[Year] =max('Date'[Year]) ))
return
Switch(True() ,
[flght] =_max , "Red",
"Green"
)
Use in conditional formatting using field value option
How to do conditional formatting by measure and apply it on pie?: https://youtu.be/RqBb5eBf_I4
@laser_beam , First of all you can not apply conditional formatting when you use measure. So what you need to do is take both Year and month on axis. then You need expand them as use concatenate label off and sort on axis(year - month), repeat steps if you do not get below
Post that create a measure . Assuming flight is the measure and you are using
Then create a color measure
Color =
var _max = calculate(maxx(Values('Date'[Month Year]), [flight ]), filter(allselected('Date') , 'Date'[Year] =max('Date'[Year]) ))
return
Switch(True() ,
[flght] =_max , "Red",
"Green"
)
Use in conditional formatting using field value option
How to do conditional formatting by measure and apply it on pie?: https://youtu.be/RqBb5eBf_I4
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 49 | |
| 40 | |
| 32 | |
| 14 | |
| 13 |
| User | Count |
|---|---|
| 87 | |
| 73 | |
| 37 | |
| 28 | |
| 26 |