WrapFormat 属性

       

该属性返回一个 WrapFormat 对象,该对象包含在指定的图形或图形区域四周文字环绕的属性。只读。

示例

本示例在活动文档中添加一个椭圆,并指定文档文字环绕该椭圆外接矩形的左右两侧。本示例将文档文字与该外接矩形四边之间的边距设置为 0.1 英寸。

Set myOval = _
    ActiveDocument.Shapes.AddShape(msoShapeOval, 36, 36, 90, 50)
With myOval.WrapFormat
    .Type = wdWrapSquare
    .Side = wdWrapBoth
    .DistanceTop = InchesToPoints(0.1)
    .DistanceBottom = InchesToPoints(0.1)
    .DistanceLeft = InchesToPoints(0.1)
    .DistanceRight = InchesToPoints(0.1)
End With