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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Fix colour of pie chart - base on field or keep them constant

Hi,

 

Is there any way I set the data colour based on the field? If not, is there any way to keep them constant?

 

I'm building reports based on different datasets. Sometimes, I have to switch datasets from one to another. The problem of mine is the colour setting might change (only at pie charts). At different datasets, the legend varies. I guess that's the main challenge of switching datasets. Unlike a bar chart or treemap, I can set the colour to be based on fields, and the problem can be solved. But I'm still struggling in any solution on a pie chart. 

 

Many Thanks.

3 REPLIES 3
v-jiascu-msft
Employee
Employee

Hi @Anonymous,

 

Which version did you use? It seems good in my test. Please refer to the snapshot below. Surely, my test is quite simple.

Fix-colour-of-pie-chart-base-on-field-or-keep-them-constant

 

Best Regards,
Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

@v-jiascu-msft

 

Hi Dale,

 

Thanks for getting back to me.

 

I'm currently using NOV 2018 version. However, this is a long-term problem of mine. I used to manually set colours for pie charts after switching data source.

 

Let me clarify my problem:

 

-------------------------------------------------------------------------------------

 

I got the same data structure with the different data source (server and database) and I had pie charts built based on tables. Here is an example of tables.

 

table1 - Data Source 1  
itemvaluecategory
a10A1
b20A2
c30A3

 

table1 - Data Source 2  
itemvaluecategory
d20B1
e10B2
f50B3

 

table1 - Data Source 3  
itemvaluecategory
g15C1
h60C2
i20A1

 

 

If I switch from data source 1 to data source 2, it should work since the category is all different. But if I switch from the data source 3 to data source 1 after switching the data source 2 to data source 3, the colour of A1 might change. (sometimes it can keep the colour setting but sometimes it cannot)

 

-------------------------------------------------------------------------------------

 

I'm glad that the colour function supports more charts so I have updated all my treemaps and bar charts with the new conditional colouring function. 

 

https://powerbi.microsoft.com/en-us/blog/power-bi-desktop-november-2018-feature-summary/#conditional...

 

 

What I'm looking for is a similar way to control the colour of pie charts. I can understand that it is not a part of the upgrade but is it on the roadmap? Or is there any other way I can achieve a similar result? 

 

Best Regards,

Lewis

Hi Lewis,

 

The conditional formatting could solve your issue. I would suggest you vote up this idea.

 

Best Regards,
Dale

Community Support Team _ Dale
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.