返回或设置外部边框的颜色。WdColorIndex,可读写。
| WdColorIndex 可以是下列 WdColorIndex 常量之一: |
| wdAuto |
| wdBlack |
| wdBlue |
| wdBrightGreen |
| wdByAuthor |
| wdDarkBlue |
| wdDarkRed |
| wdDarkYellow |
| wdGray25 |
| wdGray50 |
| wdGreen |
| wdNoHighlight |
| wdPink |
| wdRed |
| wdTeal |
| wdTurquoise |
| wdViolet |
| wdWhite |
| wdYellow |
expression.OutsideColorIndex
expression 必需。该表达式返回一个 Borders 对象。
如果将 OutsideLineStyle 属性设置为 wdLineStyleNone 或 False,则本属性的设置不会产生任何效果。
本示例在活动文档第一个表格的行列之间添加边框,然后设置内部和外部边框的颜色。
If ActiveDocument.Tables.Count >= 1 Then
Set myTable = ActiveDocument.Tables(1)
With myTable.Borders
.InsideLineStyle = True
.InsideColorIndex = wdBrightGreen
.OutsideColorIndex = wdPink
End With
End If
本示例为活动文档的第一段添加红色、0.75 磅的双边框。
With ActiveDocument.Paragraphs(1).Borders
.OutsideLineStyle = wdLineStyleDouble
.OutsideLineWidth = wdLineWidth075pt
.OutsideColorIndex = wdRed
End With