[Expand]General Information
[Expand]WinForms Controls
[Expand]ASP.NET Controls and MVC Extensions
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Collapse]WPF Controls
 [Expand]What's Installed
 [Expand].NET Core 3 Support
 [Expand]Common Concepts
 [Expand]MVVM Framework
 [Collapse]Controls and Libraries
  [Expand]Data Grid
  [Expand]Ribbon, Bars and Menu
  [Collapse]Charts Suite
   [Collapse]Chart Control
    [Expand]Getting Started
    [Expand]Providing Data
    [Collapse]Chart Elements
       Series Points
       Series Point Labels
       [Collapse]Simple Indicators
         Trend Lines
         Regression Lines
        Moving Average and Envelope
        Fibonacci Indicators
        Oscillator Indicators
        Trend Indicators
        Price Indicators
        Error Bars
       Series Titles
       Total Labels
      Chart Titles
    [Expand]Appearance Customization
    [Expand]End-User Features
    [Expand]Design-Time Features
    [Expand]Additional Resources
   [Expand]Chart3D Control
  [Expand]Pivot Grid
  [Expand]Rich Text Editor
  [Expand]Tree List
  [Expand]Gauge Controls
  [Expand]Map Control
  [Expand]Layout Management
  [Expand]Windows Modern UI
  [Expand]Data Editors
  [Expand]Navigation Controls
  [Expand]Spell Checker
  [Expand]Property Grid
  [Expand]PDF Viewer
  [Expand]TreeMap Control
  [Expand]Gantt Control
  [Expand]Diagram Control
  [Expand]Windows and Utility Controls
   Dialogs, Notifications and Panels
  [Expand]Scheduler (legacy)
 [Expand]Scaffolding Wizard
  Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Report and Dashboard Server
[Expand]eXpressApp Framework
[Expand]eXpress Persistent Objects
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation
View this topic on docs.devexpress.com (Learn more)

Trend Lines

A Trend Line is an indicator presented by a line drawn through two data points of a Series.

Expanded How to Add a Trend Line to a Chart

The following markup shows how to add two trend lines to a chart:

The table lists classes and properties required to draw trend lines:

Class or Property Description
XYSeries2D.Indicators The series collection of indicators.
TrendLine A trend line.
FinancialIndicator.Argument1 The argument of the first point.
FinancialIndicator.ValueLevel1 The value level of the first point.
FinancialIndicator.Argument2 The argument of the second point.
FinancialIndicator.ValueLevel2 The value level of the second point.
TrendLine.ExtrapolateToInfinity Specifies whether the trend line is extrapolated to infinity.
Indicator.LegendText Text that is displayed with an indicator's marker in a legend.
Indicator.ShowInLegend Specifies whether an indicator is represented in a legend.

Set the Indicator.Visible property to false when you need to hide a trend line on a chart without its removal from the Indicators collection.


To learn more about the common indicator settings, examine the Indicators help document.

Expanded See Also

Is this topic helpful?​​​​​​​