将指定的页面边框格式应用于文档中的所有节。
expression.ApplyPageBordersToAllSections
expression 必需。该表达式返回一个 Borders 对象。
本示例为活动文档的所有节添加单线型页面边框。
Dim borderLoop As Border
With ActiveDocument.Sections(1)
For Each borderLoop In .Borders
With borderLoop
.LineStyle = wdLineStyleSingle
.LineWidth = wdLineWidth050pt
End With
Next borderLoop
.Borders.ApplyPageBordersToAllSections
End With