Skip to main content
All docs
V24.2

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

DxChartAxisBase<T>.MinorTickCount Property

Specifies the number of minor ticks between two neighboring major ticks.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
[Parameter]
public int MinorTickCount { get; set; }

#Property Value

Type Description
Int32

The number of minor ticks.

#Remarks

The Chart axes initially do not display minor ticks. Set the Visible property to true to make them visible. The Chart calculates the number of minor ticks automatically. Specify the MinorTickCount property to define the number of minor ticks between two major ticks.

The following code snippet creates two minor ticks between neighboring major ticks on the value axis:

Razor
<DxChart Data="@forecasts">
    <DxChartLineSeries ArgumentField="@((WeatherForecast i) => i.Date)"
                       ValueField="@((WeatherForecast i) => i.TemperatureC)"
                       Name="Temperature, C" />
    <DxChartLineSeries ArgumentField="@((WeatherForecast i) => i.Date)"
                       ValueField="@((WeatherForecast i) => i.TemperatureF)"
                       Name="Temperature, F" />
    <DxChartValueAxis MinorTickCount="2">
        <DxChartAxisMinorTick Visible="true" />
    </DxChartValueAxis>
</DxChart>

Tick Count is 2

If you also specify the MinorTickInterval property, the desired minor tick number (MinorTickCount) might not fit the specified interval. In this case, the axis displays the number of ticks specified by the MinorTickInterval property.

The following example illustrates this behavior. Instead of 15 ticks, the value axis displays 4 ticks with the interval that equals 2:

Razor
<DxChart Data="@forecasts">
    <DxChartLineSeries ArgumentField="@((WeatherForecast i) => i.Date)"
                       ValueField="@((WeatherForecast i) => i.TemperatureC)"
                       Name="Temperature, C" />
    <DxChartLineSeries ArgumentField="@((WeatherForecast i) => i.Date)"
                       ValueField="@((WeatherForecast i) => i.TemperatureF)"
                       Name="Temperature, F" />
    <DxChartValueAxis MinorTickCount="15" MinorTickInterval="2">
        <DxChartAxisMinorTick Visible="true" />
    </DxChartValueAxis>
</DxChart>

MinorTickInterval has higher priority than MinorTickCount

See Also