CalvinGraham
Board Regular
- Joined
- Jan 27, 2010
- Messages
- 67
This has been driving me demented for about half an hour, I've tried all sorts of versions but I can't seem to access the values in the chart. I'm trying to count how many non-zero values are plotted on the bar chart and keep a tally in the variable InstancesCount:
Code:
With TheChart
ReDim TheCauses(.SeriesCollection.Count) As String
FilterType = Sheets(TheSheet).Range("ChartData_Plotted" & Right(.Name, 1)).Resize(1, 1).Offset(0, -1).Value
For ii = 1 To UBound(TheCauses)
With .SeriesCollection(ii)
TheCauses(ii) = .Name
For jj = 1 To .Points.Count
If .Values(jj) <> 0 Then InstancesCount = InstancesCount + 1
Next jj
End With
Next
End With