DefaultBorderColorIndex 属性

       

返回或设置边框的默认线条颜色。WdColorIndex,可读写。

expression.DefaultBorderColorIndex

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

注意   如果将 Borders 对象的 Enable 属性设置为 True,则边框使用默认的线条宽度、线型和颜色。

示例

本示例更改边框的默认颜色和线型,并为活动文档的第一段设置一个边框。

ActiveDocument.Paragraphs(1).Borders.Enable = True
With Options
    .DefaultBorderColorIndex = wdRed
    .DefaultBorderLineStyle = wdLineStyleDouble
End With