Extract Chart Titles from graphs
Try this
Sub Test()
Dim chtobj As Excel.ChartObject
For Each chtobj In ActiveSheet.ChartObjects
If chtobj.Chart.HasTitle Then
Debug.Print chtobj.Chart.ChartTitle.Text
End If
Next chtobj
End Sub
HTH,
Barb Reinhardt
"Excel Monkey" wrote:
I am looping through some chars in a workbook. I am trying to extract the
text from the Chart Titles. I cannot seem to get this to work using the
ChartTitle object and its Caption property. What am I doing wrong?
Dim chtobj As ChartObject
For Each chtobj In ActiveSheet.ChartObjects
Debug.Print chtobj.ChartTitle.Caption
Next
Thanks
EM
|