Rows Collection Object

Multiple objects
Multiple objects

A collection of Row objects that represent the table rows in the specified selection, range, or table.

Using the Rows Collection

Use the Rows property to return the Rows collection. The following example centers rows in the first table in the active document between the left and right margins.

ActiveDocument.Tables(1).Rows.Alignment = wdAlignRowCenter

Use the Add method to add a row to a table. The following example inserts a row before the first row in the selection.

If Selection.Information(wdWithInTable) = True Then
    Selection.Rows.Add BeforeRow:=Selection.Rows(1)
End If

Use Rows(index), where index is the index number, to return a single Row object. The index number represents the position of the row in the selection, range, or table. The following example deletes the first row in the first table in the active document.


Properties | Alignment Property | AllowBreakAcrossPages Property | AllowOverlap Property | Application Property | Borders Property | Count Property | Creator Property | DistanceBottom Property | DistanceLeft Property | DistanceRight Property | DistanceTop Property | First Property | HeadingFormat Property | Height Property | HeightRule Property | HorizontalPosition Property | Last Property | LeftIndent Property | NestingLevel Property | Parent Property | RelativeHorizontalPosition Property | RelativeVerticalPosition Property | Shading Property | SpaceBetweenColumns Property | TableDirection Property | VerticalPosition Property | WrapAroundText Property

Methods | Add Method | ConvertToText Method | Delete Method | DistributeHeight Method | Item Method | Select Method | SetHeight Method | SetLeftIndent Method

Parent Objects | Range Object | Selection Object | Table Object

Child Objects | Borders Object | Row Object | Shading Object

See Also | Cells Collection Object | Columns Collection Object