0

These little VBA language differences between Excel and Access are getting very anoying. I am at the last step (hopefully) of getting my line chart to look how I need it to, but I can't get a data label to show on the first marker only. Here is what I have so far. I have attempted every itiration I can find online and all get the same "Error 438: Object doesn't support this property or method"

With Me.ChartSpace.Charts(0).SeriesCollection(0)
    .Line.Color = sc1
    .Line.Weight = 6
    .marker.Size = 8
    .marker.Style = 2
    sName = .Name
    csName = Right(sName, Len(sName) - 8)
    .Caption = csName
    .Points(1).DataLabel.Text = csName
End With

Again, thanks for your assistance.

Michael Byars
  • 117
  • 2
  • 13

1 Answers1

0

you can try this.. please insert these line before With Statement

Me.ChartSpace.Charts(0).SeriesCollection(0).Points(1).DataLabel.Select
Selection.Format.TextFrame2.TextRange.Characters.Text = "Name"

if issue still persist then try to change Me.ChartSpace.Charts(0) to Sheets("SheetName").ChartObjects("ChartName") and put the appropriate SeriesCollection number

Maddy
  • 771
  • 5
  • 14