ShowPercentage 属性 (Word) DataLabelDataLabel.ShowPercentage property (Word)

要在图表中显示数据标签的百分比数值。True to display the percentage value for the data labels on a chart. False 可隐藏值。False to hide the value. 读/写 BooleanRead/write Boolean.

语法Syntax

表达式ShowPercentageexpression.ShowPercentage

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

示例Example

以下示例显示第一个图表上第一个系列的数据标签的百分比值。The following example enables the percentage value to be shown for the data labels of the first series on the first chart.

With ActiveDocument.InlineShapes(1) 
 If .HasChart Then 
 .Chart.SeriesCollection(1).DataLabels. _ 
 ShowPercentage = True 
 End If 
End With

另请参阅See also

DataLabel 对象DataLabel Object

支持和反馈Support and feedback

有关于 Office VBA 或本文档的疑问或反馈?Have questions or feedback about Office VBA or this documentation? 请参阅 Office VBA 支持和反馈,获取有关如何接收支持和提供反馈的指南。Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.