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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
Anonymous
Not applicable

Stacked Bar Chart Tooltips

Hi All, 

 

I have a stacked bar chart where i've brought in 3 measures: 

1. Measure 1 calculates total sales for the selected financial year (based on slicer selection) 

2. Measure 2 calculates total sales for the selected financial year minus 1 

3. Measure 3 calculates total sales for the selected financial year minus 2 

 

Is there a way to create a dyanmic tooltip where when a user hovers over the stacked bar chart, depending on which year they're hovering over, it shows the year details. 

 

For example, in a stacked bar chart that has three years stacked, if i hover over FY20-21, i want my tooltip to show a measure that basically returns the year they're hovering over. BEcause i can't hardcode the year name, how do i make this dynamic in a tooltip? 

 

Thanks in advance. Any suggestions are appreciated. 

4 REPLIES 4
Mayank_Yavda
Resolver II
Resolver II

Hi @Anonymous ,

 

Here is Stacked Column Chart with Custom Tooltip which will help you get separate or ungrouped tooltip for each stack.

 

Stacked Column Chart with custom tooltip PBIVizEdit.comStacked Column Chart with custom tooltip PBIVizEdit.comStacked Column Chart with custom tooltip PBIVizEdit.comStacked Column Chart with custom tooltip PBIVizEdit.com

 

Download link for the custom visual file in this page

https://pbivizedit.com/gallery/stacked-column-with-custom-tooltip 

 

This was made with our Custom Visual creator tool PBIVizEdit.com. With this tool,

  • anyone, irrespective of technical skills, can create their own visuals
  • 15 minutes to create a visual from scratch
  • opens up many additional attributes to edit (for e.g. labels, tooltips, legends position, etc)

Give this a shot and let us know if you face any problem/errors.
You can use the editor to modify your visual further (some modifications cannot be done in Power BI window and have to be in editor).

Thanks,
Team PBIVizEdit

v-xiaotang
Community Support
Community Support

Hi @Anonymous 

What are the values in your graph? Can you take a screenshot showing your current visual?

 

Best Regards,

Community Support Team _Tang

If this post helps, please consider Accept it as the solution to help the other members find it more quickly.

lbendlin
Super User
Super User

Stacked Bar charts support custom tooltip pages. Using report tooltip pages in Power BI - Power BI | Microsoft Docs

Anonymous
Not applicable

Thanks for that. 

I think the issue i'm facing is mostly around how my measures have been formed. Instead of using date column to break up the stacks, i've used measures that return previous year and previous year - 1 based on slicer selection. As a result, when i hover over the stacks, it doesn't tell me which year i'm hovering over.

I'm assuming i need a switch statement but i can't seem to make it work. 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

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

Top Solution Authors