What I have been atempting to do is access the the Text, Font and Color properties with the code listed below. I can access the text, but color and font properties im not able to get. The code executes, but the color and font values are not correct. The bottom line is that I dont fully understand the seriesCollection is implemnted for the legend. If anyone knows I would appreciate any comment. Tony
For i = .SeriesCollection.Count To 1 Step -1
With .SeriesCollection(i)
oChart.TrendLegend.SetText(i) = .Name
oChart.TrendLegend.SetColor(i) = .Color
oChart.TrendLegend.SetVisible(i) = True
oChart.TrendLegend.SetFontSize(i) = .size
ActiveChart.Legend.LegendEntries(i).Select
With Selection
Call oChart.TrendLegend.SetPosition(i, .Width, .Height, .Top, .Left)
End With
next i
For i = .SeriesCollection.Count To 1 Step -1
With .SeriesCollection(i)
oChart.TrendLegend.SetText(i) = .Name
oChart.TrendLegend.SetColor(i) = .Color
oChart.TrendLegend.SetVisible(i) = True
oChart.TrendLegend.SetFontSize(i) = .size
ActiveChart.Legend.LegendEntries(i).Select
With Selection
Call oChart.TrendLegend.SetPosition(i, .Width, .Height, .Top, .Left)
End With
next i
Last edited: