March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
I am new to power bi and facing difficulty in splitting the colors on the same bar in stacked bar chart. I have reached to this and cannot split colors on bar. Please help me with this.
Solved! Go to Solution.
Hi @abdulrafey ,
Based on your description, you want to color split the bars by type. There are two prerequisites to accomplish this step, first for your sub-Category you need to have more than one under the same Category, as this is the category that is used as a measure of the length of the bar chart. Secondly you need to use stuck bar chart for this.
Here some steps that I want to share, you can check them if they suitable for your requirement.
Here is my test data:
Final output
Best regards,
Albert He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @abdulrafey ,
Based on your description, you want to color split the bars by type. There are two prerequisites to accomplish this step, first for your sub-Category you need to have more than one under the same Category, as this is the category that is used as a measure of the length of the bar chart. Secondly you need to use stuck bar chart for this.
Here some steps that I want to share, you can check them if they suitable for your requirement.
Here is my test data:
Final output
Best regards,
Albert He
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
When you say you are having difficulty splitting the color on the same bar - are you wanting the sub-categories to appear in the same bar, but different colors or are you wanting something else?
Proud to be a Super User! | |
hi @abdulrafey ,
Instead of adding Sub-category in legend, add it in the Y-asix below Category and check.
I hope this is what you are looking for, please feel free to ask if you any further query.
Thank You
Vivek
Sorry, it doesn't works. Please tell me the general way of doing it, do we have to write any query for data range. And what is DAX query and where it is written?
@abdulrafey
No need of DAX its simple, with previous solution you need to click on drill down button, and then hold ctrl+ click on the specific bar.
You are not able to see the color splitting cause all the 6 cells of category and sub-category are different.
please check this video, to understand how to use bar chart. https://youtu.be/_LYN02Fi4Wo?si=A6QknXuY67k_FDNF
Thank you.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
123 | |
86 | |
76 | |
57 | |
52 |
User | Count |
---|---|
201 | |
137 | |
108 | |
73 | |
68 |