CategoryType 属性

返回或设置分类轴类型。XlCategoryType 类型,可读写。

XlCategoryType 可为以下 XlCategoryType 常量之一。

xlCategoryScale

xlAutomaticScale

xlTimeScale

expression CategoryType

expression   必需。该表达式返回“应用于”列表中的对象之一。

说明

不能对数值轴设置本属性。

示例

本示例使图表中的分类轴使用时间刻度,并以月为基本单位。

With myChart

    With .Axes(xlCategory)

        .CategoryType = xlTimeScale

        .BaseUnit = xlMonths

    End With

End With