View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Chad[_3_] Chad[_3_] is offline
external usenet poster
 
Posts: 32
Default Adding Labels to a XY Chart

Hi All,

I am trying to write a chunk of code that adds labels to my XY chart.
Basically I code is very simple

ActiveWorkbook.Sheets(pChartSheet).SeriesCollectio n(1).Points(199).DataLabel.Text
= "199"

That line works fine, but

ActiveWorkbook.Sheets(pChartSheet).SeriesCollectio n(1).Points(200).DataLabel.Text
= "200"

fails with the falling error "Runtime Error 1004"

My source data has 215 entries so, 1-199 works fine, but 200 + fails.

Any ideas why?

Thanks
Chad