Forum Discussion
Pie Chart Colours Keep Changing
Actually what you can do is colouring the piechart or any chart with FX.
My task was quite similar today, I had to give fix colours to Currencies. I have created a measure based on the existing currencies in the dataset:
ColourPalette =
SWITCH(true(),
Table1[Currency] = "USD", "#e044a7",
Table1[Currency] = "GBP", "#118dff",
Table1[Currency] = "EUR", "#12239e",
Table1[Currency] = "SEK", "#6b007b",
Table1[Currency] = "NOK", "#e66c37"
)Once I've done this one, created a pie chart, but as you can see in the screenshot, there is no option for FX colouring:
So, I just changed the chart to a bar chart, and there was an FX option.
Clicking on the FX option, I set the Format Style ->Field Value, and selected the ColourPalette measure, I have created. Once I saved the colour of the bar chart changed based on the ColourPalette. After that I just changed back the Bar chart to a pie chart, and the colours are staying as well. Also in PowerBI service, because there is an FX format in the background somewhere 😄
Please mark as Solution if it worked for you 🙂