BorderThemeColorIndex 属性 (权限)CommandButton.BorderThemeColorIndex property (Access)

获取或设置一个值,该值代表与指定对象的 边框颜色 属性相关联的应用的颜色主题中的颜色。Gets or sets a value that represents a color in the applied color theme associated with the BorderColor property of the specified object. 读/写 Read/write Long.

语法Syntax

表达式BorderThemeColorIndexexpression.BorderThemeColorIndex

_表达式_一个代表**命令按钮** 对象的变量。expression A variable that represents a CommandButton object.

说明Remarks

BorderThemeColorIndex 属性包含下表中列出的索引值之一。The BorderThemeColorIndex property contains one of the index values listed in the following table.

索引值Index value 说明Description
00 文字 1Text 1
11 背景 1Background 1
双面2 文字 2Text 2
第三章3 背景 2Background 2
44 强调文字颜色 1Accent 1
55 强调文字颜色 2Accent 2
6 强调文字颜色 3Accent 3
7 强调文字颜色 4Accent 4
utf-88 强调文字颜色 5Accent 5
9 强调文字颜色 6Accent 6
1010 超链接Hyperlink
11x1711 已访问的超链接Followed Hyperlink

如果应用了无主题,则 BorderThemeColorIndex 属性包含-1。If no theme is applied, the BorderThemeColorIndex property contains -1.

此属性未出现在属性表中。This property is not surfaced in the property sheet.

示例Example

下面的代码示例通过设置BorderThemeColorIndex属性, 将边框颜色设置为文本2的颜色。The following code example sets the border color to the Text 2 color by setting the BorderThemeColorIndex property.

Me.ctl.BorderThemeColorIndex=2

支持和反馈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.