Back to Devexpress

Axis.BaseTimeUnit Property

officefileapi-devexpress-dot-spreadsheet-dot-charts-dot-axis-cdae1353.md

latest2.9 KB
Original Source

Axis.BaseTimeUnit Property

Gets or sets the base unit for the date axis.

Namespace : DevExpress.Spreadsheet.Charts

Assembly : DevExpress.Spreadsheet.v25.2.Core.dll

NuGet Package : DevExpress.Spreadsheet.Core

Declaration

csharp
AxisTimeUnits BaseTimeUnit { get; set; }
vb
Property BaseTimeUnit As AxisTimeUnits

Property Value

TypeDescription
AxisTimeUnits

An AxisTimeUnits enumeration value specifying the base time unit.

|

Available values:

NameDescription
Auto

Specifies that the time unit for the date axis should be set automatically.

| | Days |

Specifies that days should be used as the time unit for the date axis, so the chart data will be plotted along the axis in days.

| | Months |

Specifies that months should be used as the time unit for the date axis, so the chart data will be plotted along the axis in months.

| | Years |

Specifies that years should be used as the time unit for the date axis, so the chart data will be plotted along the axis in years.

|

Remarks

The base unit is a fundamental unit that specifies how to plot data along the date axis: in days, months, or years. By default, the BaseTimeUnit property is set to AxisTimeUnits.Auto, so the base unit is evaluated automatically based on the smallest difference between any two dates in a worksheet.

You can also specify the time unit for major and minor tick marks on the axis by utilizing the Axis.MajorTimeUnit and Axis.MinorTimeUnit properties. To set the distance between these tick marks, use the Axis.MajorUnit and Axis.MinorUnit properties.

See Also

MajorTimeUnit

MajorUnit

MinorTimeUnit

MinorUnit

Axis Interface

Axis Members

DevExpress.Spreadsheet.Charts Namespace