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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Tree Diagram Configuration.

I noticed that there is a option to use function to determin the color of the boxes (IF I DON'T PUT DETAILS)

 

GAPER_0-1698972694045.png

GAPER_1-1698972706676.png

 

however once i put details in. The colors is fixed which I can't change using a formular. 

 

GAPER_3-1698972831152.png

 

GAPER_2-1698972770423.png

 

My goal is to have the groupping like case 2. But also having the flexbility to dynamically determine the coloring like case 1. Anyone knows what to do about this?

2 REPLIES 2
Anonymous
Not applicable

How do you have the cells that from the same brand close to each other. 

amitchandak
Super User
Super User

@Anonymous , Power Bi conditional formatting is not supported with once you use details in tree map.

 

Move both of them  category expand and the use conditional formatting

amitchandak_0-1698979825324.png

 

color on brand has been used with help measure and field value formatting

 

Brand Color = Switch( true(),
max('Item'[brand]) = "Brand 1" , "red",
max('Item'[brand]) = "Brand 2" , "blue",
max('Item'[brand]) = "Brand 3" , "green",
max('Item'[brand]) = "Brand 4" , "gray",
max('Item'[brand]) = "Brand 5" , "yellow",
max('Item'[brand]) = "Brand 6" , "orange",
max('Item'[brand]) = "Brand 7" , "brown",
max('Item'[brand]) = "Brand 8" , "Cyan",
max('Item'[brand]) = "Brand 9" , "Tan",
max('Item'[brand]) = "Brand 10" , "Violet",
max('Item'[brand]) = "Brand 11" , "Gold",
"silver"
)

 

amitchandak_1-1698979868800.png

 

 

 

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

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.