April 2006
Beginner
1114 pages
98h 16m
English
series.Trendlines([Index])
Returns one or all of the Trendline objects for a series. Use the Trendlines collection to add trendlines to a series as shown by the following code:
Sub AddTrendline( )
Dim chrt As Chart, sr As Series, tl As Trendline
' Get a chart.
Set chrt = ActiveChart
' Get first series
Set sr = chrt.SeriesCollection(1)
' Add a trendline
Set tl = sr.Trendlines.Add
tl.Type = xlMovingAvg
End SubRead now
Unlock full access