A
angy345
Hi, i hope someone will be able to help me on that one. I want on the
line graph to show the data points that are above and below the average
control line to be of a diffenrent colour. For the moment i am only
trying to the points that are equal to between 0 and 7 to be of a
different colour.
Below is the code to do so but i get an error msg saying that the
object doesnt support method or property. Can anyone tell me where am i
going wrong here.
Sub ComponentValue()
Dim i As Integer, CompVal As Integer
Dim dpoint As Point
i = 1
For Each dpoint In ActiveChart.SeriesCollection(4).Point(i)
CompVal = WorksheetFunction.Max(dpoint)
If CompVal >= 1 Or CompVal <= 7 Then
With ActiveChart.SeriesCollection(4).Points(i)
..MarkerBackgroundColorIndex = 3
..MarkerForegroundColorIndex = 3
i = i + 1
End With
End If
Next
End Sub
Any help and comment are most welcome
Thank you in advance
Angel
line graph to show the data points that are above and below the average
control line to be of a diffenrent colour. For the moment i am only
trying to the points that are equal to between 0 and 7 to be of a
different colour.
Below is the code to do so but i get an error msg saying that the
object doesnt support method or property. Can anyone tell me where am i
going wrong here.
Sub ComponentValue()
Dim i As Integer, CompVal As Integer
Dim dpoint As Point
i = 1
For Each dpoint In ActiveChart.SeriesCollection(4).Point(i)
CompVal = WorksheetFunction.Max(dpoint)
If CompVal >= 1 Or CompVal <= 7 Then
With ActiveChart.SeriesCollection(4).Points(i)
..MarkerBackgroundColorIndex = 3
..MarkerForegroundColorIndex = 3
i = i + 1
End With
End If
Next
End Sub
Any help and comment are most welcome
Thank you in advance
Angel