Hi All,
How to get the selected series index number of a chart?
Thanks for the help,
Rgds,
Balumail75.
Hi All,
How to get the selected series index number of a chart?
Thanks for the help,
Rgds,
Balumail75.
two ways you can check out and test:[VBA]Sub dlah()
If TypeName(Selection) = "Series" Then
Set ch = ActiveChart.SeriesCollection
For I = 1 To ch.Count
If ch(I).Name = Selection.Name Then MsgBox "index is " & I
Next I
'also:
aa = Selection.Formula
bb = Mid(aa, InStrRev(aa, ",") + 1)
MsgBox "also, index is " & Left(bb, Len(bb) - 1)
End If
End Sub
[/VBA]
p45cal
Everyone: If I've helped and you can't be bothered to acknowledge it, I can't be bothered to look at further posts from you.