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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
bdehning
Post Prodigy
Post Prodigy

Automating Column colors for each year

I currently use Clustered Column Chart to show data by a field called Inception Year.  I select and set the colors for eacy year by Formating Columns and applying Series settings for each year and selecting a color for each year.  But I have to each Januay go in add a new color fo the new year.  

What do I need to do to set this column chart up so it automating creates a new color going forward for 2027, 2028 and beyond? 

14 REPLIES 14
v-pnaroju-msft
Community Support
Community Support

Hi bdehning,

Thank you for sharing your idea in the Ideas forum. We appreciate your contribution, and we have also upvoted the idea. Please note that Microsoft regularly reviews ideas submitted by the community, and your suggestion may be considered for future updates.

Thank you once again, and we encourage you to continue engaging with the Microsoft Fabric Community.

v-pnaroju-msft
Community Support
Community Support

Hi bdehning,

Thank you for the update. If legend based conditional colour formatting is essential for your scenario, we kindly request you to submit an idea in the Ideas forum using the link: Fabric Ideas - Microsoft Fabric Community so that the product team may evaluate it.

If you have any further queries, please feel free to contact the Microsoft Fabric community.

Thank you.

Hi @bdehning ,

Could you please confirm if you've submitted this as an idea in the Ideas Forum? If so, sharing the link here would be helpful for other community members who may have similar feedback.

Best Regards, 
Community Support Team 

v-pnaroju-msft
Community Support
Community Support

Hi bdehning,

We would like to follow up and see whether the details we shared have resolved your problem. If you need any more assistance, please feel free to connect with the Microsoft Fabric community.

Thank you.

No it can not be done as Microsoft removed the function i needed

v-pnaroju-msft
Community Support
Community Support

Thankyou, @amitchandak@cengizhanarslan@RicardoTraNa , @danextian@Thejeswar, and @Praful_Potphode for your responses.

Hi bdehning,

Based on our understanding, when a field is placed in the Legend of a clustered column chart, Power BI automatically controls the series colours. In this configuration, the “fx” Field Value conditional formatting option is not available. 

As per our research, there is no official documentation confirming that legend-based conditional formatting for column charts is being restored. Therefore, we should consider the current behaviour as the supported design.

As noted by @danextian , conditional formatting does not apply when a Legend controls the series. Additionally, as suggested by @RicardoTraNa , the correct long term approach is to remove manual colour overrides and allow Power BI to utilise the default theme palette.

vpnarojumsft_0-1771844052626.png

Additionally, please refer to the links below:
Apply Conditional Table Formatting in Power BI - Power BI | Microsoft Learn
Customize Power BI Visualization Titles - Power BI | Microsoft Learn
Conditional formatting in Power BI visuals - Power BI | Microsoft Learn
Tips and Tricks for Formatting in Reports - Power BI | Microsoft Learn

We hope the information provided helps to resolve the issue. Should you have any further queries, please feel free to contact the Microsoft Fabric community.

Thank you.




Praful_Potphode
Super User
Super User

Hi @bdehning 

try attached PBIX.please note that i have assumed that we have only X Axis and Y Axis on CLustered column chart.If we have legend field then this apparoch may not work.

 

Please give kudos or mark it as solution once confirmed.

 

Thanks and Regards,

praful

Thejeswar
Super User
Super User

Hi @bdehning ,

In case our clustered column chart does not use a legend to split the data then you can use a calculated column to apply conditional formatting to the fields. That way every January will have a certain color, February will have a certain color and so on.

 

It is a limitation that you can use conditional formatting when there is a legend in use in the visual

 

Regards,

danextian
Super User
Super User

Hi @bdehning 

It depends on how the column chart is configured. If a legend is used to split the values by year, automating it isn’t currently possible. Conditional formatting only works when no legend is applied to the column or combo chart. A workaround is to pre-assign values to future years by having them exist in the model even if your current data shows only up to the current and then use a measure that will not return blank for any of the year. Example: 

Some value = 1

danextian_0-1771400743557.png

 





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.
RicardoTraNa
Resolver IV
Resolver IV

Hey!  You can use automatic category colors instead of setting a color per year manually.

In your clustered column chart, remove the custom series color overrides and let the visual use the default color palette (Format > Data colors > Reset to default / turn off “Show all”). Then each new Inception Year (2027, 2028, etc.) will automatically get the next color with no yearly maintenance.

If later you need controlled logic, you can switch to conditional formatting with a DAX color measure ... but first step is to stop hardcoding colors per year.

Best Regards! 

cengizhanarslan
Super User
Super User

Power BI does not support dynamic “auto-assign new color per new category” logic for specific values. The easiest approach would be instead of manually assigning colors, let DAX control the color.

 

Step 1) Create a color measure

Year Color =
VAR Yr = SELECTEDVALUE('Table'[Inception Year])
RETURN
SWITCH(
    TRUE(),
    Yr = 2024, "#4472C4",
    Yr = 2025, "#ED7D31",
    Yr = 2026, "#70AD47",
    "#A5A5A5"   -- default color for future years
)

 

Step 2) Apply to visual

  • Format → Data colors → fx

  • Format by: Field value

  • Based on field: Year Color

_________________________________________________________
If this helped, ✓ Mark as Solution | Kudos appreciated
Connect on LinkedIn | Follow on Medium
AI-assisted tools are used solely for wording support. All conclusions are independently reviewed.
amitchandak
Super User
Super User

@bdehning , If you are not using legend or two measures, you can use field - conditional formatting. You can create a measure like below and use in coditional formatting using field value option 

 

COlor = Switch(True() ,

max(Table[Inception Year])  = Year(Today()) , "Blue", 

max(Table[Inception Year])  = Year(Today()) -1 , "Green", 

"Red"

 

How to do conditional formatting by measure and apply it on pie?
https://www.youtube.com/watch?v=RqBb5eBf_I4&list=PLPaNVDMhUXGYo50Ajmr4SgSV9HIQLxc8L
https://community.powerbi.com/t5/Community-Blog/Power-BI-Conditional-formatting-the-Pie-Visual/ba-p/...
https://amitchandak.medium.com/power-bi-where-is-the-conditional-formatting-option-in-new-format-pan...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

It seems from my research that the functions for conditional formatting have been removed by Microsoft with this new rollout. There is supposed to be an option to revert to Classic visual from Modern visual but for our current PBI tenent, we cannot revert.

 

I heard they may restore all those features over the next months, but anyone else know anything abut this.  

I tried all kinds of options but FX never appeared unless I removed the year field in Legend, so never got what I wanted.      

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

Check out the February 2026 Power BI update to learn about new features.