View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Trevor Williams Trevor Williams is offline
external usenet poster
 
Posts: 181
Default XL2002 - SeriesCollection.Index

I'm getting an error using the following code - seems like I can't use .Index
with the SeriesCollection... Is that right?

If so, what should I be using?

Thanks in advance

Trevor
---------------------------------------

ActiveSheet.ChartObjects("Chart 1").Activate

sCount = ActiveChart.SeriesCollection.Count
xCount = sCount / 2 + 1

For Each mySeries In ActiveSheet.ChartObjects("Chart
1").Chart.SeriesCollection
If mySeries.Index xCount Then
mySeries.Delete
End If
Next