Forum Discussion
Dynamic Hierarchy selection with slicer - data labels not displaying correctly
I am creating a dashboard where I would like the users to have the ability to select a level of a hierarchy to display the distribution of that hierarchy for a set of categories. I made use of this blog post on how to set dynamic categories/legends, which works perfectly with the exception of the data labels. (https://xxlbi.com/blog/dynamic-hierarchies-in-power-bi/) For the 100% stacked bar chart, I would need the Legend to reflect the level the user selects in the slicer. Here's what I am seeing, the top stacked chart is with the dynamic selection, the bottom is without. The distribution for both is correctly sliced, however the data label for the dynamic version is showing 0.0% instead of the expected % distribution. I'm not sure why this doesn't display correctly in the dynamic legend scenario, any ideas on this? When I hover over the top chart, the tool tip does show the correct % distribution.
- Anonymous5 years ago
That unfortunately didn't work - for whatever reason, when I went back and re-created the visualization from scratch, it seemed to work with the correct data values showing. (I had at first just changed the chart from a regular bar to the stacked %) I am not sure why that worked vs. changing the chart type, but it's fixed now.
2 Replies
- v-luwang-msft
Community Support
Hi Anonymous ,
Try to change the decimals up or down and then set it to zero again. I hope that this helps!
If possible, please share your .pbix file and remove confidential data.
Best Regards
Lucien
- AnonymousNot applicable
That unfortunately didn't work - for whatever reason, when I went back and re-created the visualization from scratch, it seemed to work with the correct data values showing. (I had at first just changed the chart from a regular bar to the stacked %) I am not sure why that worked vs. changing the chart type, but it's fixed now.