Skip to main content
A newer version of this page is available. .

DxChartConstantLine Class

Specifies an axis constant line.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v20.2.dll

NuGet Package: DevExpress.Blazor

Declaration

public class DxChartConstantLine :
    DxComplexSettingsComponent<DxChartConstantLine, ChartConstantLineModel>,
    IModelProvider<ChartConstantLineLabelModel>

Remarks

Use the DxChartConstantLine component to mark an individual axis value. To set the value, use the DxChartConstantLine.Value property. A constant line’s label initially displays this value. Use the DxChartConstantLineLabel.Text property to change label text.

You can add any number of constant lines for the chart’s argument and value axis.

<DxChartArgumentAxis>
    <DxChartConstantLine Value="@("2019-Dec-31")">
        <DxChartConstantLineLabel Text="Current Date" 
                                  VerticalAlignment="VerticalAlignment.Center" 
                                  Position="RelativePosition.Inside"/>
    </DxChartConstantLine>
    ...
</DxChartArgumentAxis>
<DxChartValueAxis>
    <DxChartConstantLine Value="50" >
        <DxChartConstantLineLabel Text="Average"
                                  HorizontalAlignment="HorizontalAlignment.Center"
                                  Position="RelativePosition.Inside" />
    </DxChartConstantLine>
    <DxChartConstantLine Value="100"/>
    ...
</DxChartValueAxis>

Inheritance

Object
ComponentBase
DxSettingsComponent<DevExpress.Blazor.Internal.ChartConstantLineModel>
DxComplexSettingsComponent<DxChartConstantLine, DevExpress.Blazor.Internal.ChartConstantLineModel>
DxChartConstantLine
See Also