PDA

View Full Version : Referring to Trendline by name



SedM
01-09-2006, 08:40 AM
I create a trendline and give it the name of "Trend_1"
Later I want to delete/modify this line by referring to it by name (not index number which I think can change).
Can I do this?
Des

austenr
01-09-2006, 09:15 AM
Perhaps something like this:

Worksheets("sheet1").ChartObjects(1).Chart.SeriesCollection(1) _
.Trendlines.delete Type:=xlLinear, Name:="Trendline1"