TickLabels.Offset 属性 (Excel)TickLabels.Offset property (Excel)

返回或设置一个Long值,该值代表第一级与坐标轴之间的距离标签的级别之间的距离。Returns or sets a Long value that represents the distance between the levels of labels, and the distance between the first level and the axis line.

语法Syntax

expressionexpression. Offset

_表达式_一个代表TickLabels对象的变量。expression A variable that represents a TickLabels object.

说明Remarks

其默认距离为百分之百,代表坐标轴标签之间以及标签与坐标轴线之间的默认距离。The default distance is 100 percent, which represents the default spacing between the axis labels and the axis line. 其值可以为从 0 到 1000 之间的一个整数百分比,表示相对于坐标轴标签的字号。The value can be an integer percentage from 0 through 1000, relative to the axis label's font size.

示例Example

如果偏移量小于 500,则此示例将 Chart1 中分类轴上标签之间的距离设置为当前距离的两倍。This example sets the label spacing of the category axis in Chart1 to twice the current setting, if the offset is less than 500.

With Charts("Chart1").Axes(xlCategory).TickLabels 
 If .Offset < 500 then 
 .Offset = .Offset * 2 
 End If 
End With

另请参阅See also

TickLabels 对象TickLabels Object