View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Chrissy[_4_] Chrissy[_4_] is offline
external usenet poster
 
Posts: 101
Default Looping Through Chart Labels

Here is some starting code for you.

Dim DL As DataLabel

ActiveChart.ApplyDataLabels ShowValue:=True

For Each DL In ActiveChart.SeriesCollection(1).DataLabels
If CDbl(Left(DL.Text, Len(DL.Text) - 1)) < 3 Then
DL.Delete
End If
Next


Chrissy.

"Dan Gesshel" wrote in message ...
Hello.

I am trying to write a loop (such as a For...Next or Do Until) to loop
through all the Datalabels in a chart, evaluate whether they are below 3%
value, and if so to remove the labels.

There is only one SeriesCollection with multiple points (about 50.)

I have written this code before to success, but using a Range to check for
the value and not in a loop. Anyone out there help me or point me in the
right direction? I appreciate the help.

Thanks

Dan