在所选内容的上方插入指定数量的新行。如果所选内容不在表格中,则会导致出错。
注意 用 Rows 对象的 Add 方法也可插入行。
expression.InsertRows(NumRows)
expression 必需。该表达式返回一个 Selection 对象。
NumRows Variant 类型,可选。需要添加的行数。
本示例在所选内容的上方插入两个新行,然后删除新行的边框。
If Selection.Information(wdWithInTable) = True Then
Selection.InsertRows NumRows:=2
Selection.Borders.Enable =False
End If