Highlight Charts when we hover on them

Rachel Stem

New Member
Joined
Dec 21, 2016
Messages
1
Hello,

I have a dashboard with multiple charts . Now is there a way to link all these charts such that when I hover on one chart (say I hover on the year 2006 of Column Chart 1) then all the other charts for that year should get highlighted.
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
Hi Rachel,

Welcome to the Board.

Charts are considered Shapes and will respond to a Click event but not to a hover or mouse over. There is a workaround that might get you close to what you want...

From the Developer tab, insert an ActiveX Label over the 2006 of Column Chart 1. Right click the Label and select the Properties option; set the BackStyle to transparent and clear the Caption.

Double click the Label to view the code window and choose MouseMove from the upper right selection options... then enter your highlight code or whatever else you want to do. In the example below there are two transparent labels - the first label MouseMove will select/highlilght charts 2 and 3, the second MouseMove will select a range (to unhighlight the charts.)

Code:
Private Sub Label1_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
    ActiveSheet.Shapes.Range(Array("Chart 3", "Chart 2")).Select
End Sub

Private Sub Label2_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single)
    Range("A1").Select
End Sub

Cheers,

tonyyy

p.s. Note to @WarfritLive - You can embed a hyperlink in a cell such that a mouseover will call a macro, to highlight the cell or do some other action.
 
Upvote 0

Forum statistics

Threads
1,214,646
Messages
6,120,717
Members
448,985
Latest member
chocbudda

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top