Trendline Trendline Trendline Interface
Represents a trendline in a chart.
public interface class Trendline
[System.Runtime.InteropServices.Guid("91C46192-3124-4346-A815-10B8873F5A06")] public interface Trendline
Public Interface Trendline
The index number denotes the order in which the trendlines were added to the series. Trendlines(1) is the first trendline added to the series, and Trendlines(Trendlines.Count) is the last one added.
The following example changes the trendline type for the first series of the first chart in the active document. If the series has no trendline, this example will fail.
A trendline shows the trend, or direction, of data in a series. The Trendline object is a member of the Trendlines collection. The Trendlines collection contains all the Trendline objects for a single series.
|Application Application Application||
When used without an object qualifier, this property returns an _Application object that represents the Microsoft Word application. When used with an object qualifier, this property returns an Application object that represents the creator of the specified object (you can use this property with an OLE Automation object to return the application of that object). Read-only.
|Backward Backward Backward||
Returns or sets the number of periods (or units on a scatter chart) that the trendline extends backward.
|Backward2 Backward2 Backward2||
Returns or sets the number of periods (or units on a scatter chart) that the trendline extends backward. Read/write Double.
|Border Border Border||
Returns a ChartBorder object that represents the border of the object. Read-only.
|Creator Creator Creator||
Returns a 32-bit integer that indicates the application in which the specified object was created. Read-only Integer.
|DataLabel DataLabel DataLabel||
Returns a DataLabel object that represents the data label associated with the trendline. Read-only.
|DisplayEquation DisplayEquation DisplayEquation||
True if the equation for the trendline is displayed on the chart (in the same data label as the R-squared value). Setting this property to True automatically turns on data labels. Read/write Boolean.
|DisplayRSquared DisplayRSquared DisplayRSquared||
True if the R-squared value of the trendline is displayed on the chart (in the same data label as the equation). Setting this property to True automatically turns on data labels. Read/write Boolean.
|Format Format Format||
Returns the line, fill, and effect formatting for the object. Read-only ChartFormat.
|Forward Forward Forward||
Returns or sets the number of periods (or units on a scatter chart) that the trendline extends forward.
|Forward2 Forward2 Forward2||
Returns or sets the number of periods (or units on a scatter chart) that the trendline extends forward. Read/write Double.
|Index Index Index||
Returns the index number of the object within the collection of similar objects.
|Intercept Intercept Intercept||
Returns or sets the point where the trendline crosses the value axis. Read/write Double.
|InterceptIsAuto InterceptIsAuto InterceptIsAuto||
True if the point where the trendline crosses the value axis is automatically determined by the regression. Read/write Boolean.
|Name Name Name||
Returns or sets a String value that represents the name of the object.
|NameIsAuto NameIsAuto NameIsAuto||
True if Microsoft Word automatically determines the name of the trendline. Read/write Boolean.
|Order Order Order|
|Parent Parent Parent||
Returns the parent for the specified object. Read-only Object.
|Period Period Period||
Returns or sets the period for the moving-average trendline. Can be a value from 2 through 255. Read/write Integer.
|Type Type Type||
Returns or sets a XlTrendlineType value that represents the trendline type.
|ClearFormats() ClearFormats() ClearFormats()||
Clears the formatting of the object.
|Delete() Delete() Delete()||
Deletes the object.
|Select() Select() Select()||
Selects the object.