Axis![]() ![]() ![]() |
代表图表坐标轴标题。
可用 AxisTitle 属性返回一个 AxisTitle 对象。下例激活第一个嵌入图表,设置其数值轴标题文本,将其字体设为 10 磅的“Bookman”字体,并将单词“millions”设为倾斜。
Worksheets("sheet1").ChartObjects(1).Activate
With ActiveChart.Axes(xlValue)
.HasTitle = True
With .AxisTitle
.Caption = "Revenue (millions)"
.Font.Name = "bookman"
.Font.Size = 10
.Characters(10, 8).Font.Italic = True
End With
End With
只有将坐标轴的 HasTitle 属性设置为 True 后,才存在 AxisTitle 对象,从而才能使用该对象。