Megan -
I don't think you can improve on these two options. I once wrote a
utility like Tushar's, and it worked pretty well, except for this
blinking annoyance.
If you are using an embedded chart, and want to put information into the
nearby cells, the following works without much flicker. It puts
information into the worksheet about the last point the mouse went over,
while ignoring any of the other chart elements. The chart has to be
selected, and you have to have set up a chart events class module first.
Private Sub EmbChart_MouseMove _
(ByVal Button As Long, ByVal Shift As Long, _
ByVal X As Long, ByVal Y As Long)
Dim ElementID As Long, Arg1 As Long, Arg2 As Long
Dim myX As Double, myY As Double
With EmbChart
.GetChartElement X, Y, ElementID, Arg1, Arg2
If ElementID = xlSeries Or ElementID = xlDataLabel Then
If Arg2 > 0 Then
myX = WorksheetFunction.Index _
(.SeriesCollection(Arg1).XValues, Arg2)
myY = WorksheetFunction.Index _
(.SeriesCollection(Arg1).Values, Arg2)
ActiveSheet.Range("J2:J6") = WorksheetFunction _
.Transpose(Array("Series " & Arg1, _
"""" & .SeriesCollection(Arg1).Name & """", _
"Point " & Arg2, _
"X = " & myX, _
"Y = " & myY))
End If
End If
End With
End Sub
- Jon