Row.SetLeftIndent method (Word)

Sets the indentation for a row in a table.

Syntax

expression. SetLeftIndent( _LeftIndent_ , _RulerStyle_ )

expression Required. A variable that represents a 'Row' object.

Parameters

Name Required/Optional Data type Description
LeftIndent Required Single The distance (in points) between the current left edge of the specified row or rows and the desired left edge.
RulerStyle Required WdRulerStyle Controls the way Word adjusts the table when the left indent is changed.

Remarks

The WdRulerStyle behavior described above applies to left-aligned tables. The WdRulerStyle behavior for center- and right-aligned tables can be unexpected; in these cases, use the SetLeftIndent method with care.

Example

This example creates a table in a new document and indents the first row 0.5 inch (36 points). When you change the left indent, the cell widths are adjusted to preserve the right edge of the table.

Dim docNew As Document 
Dim tableNew As Table 
 
Set docNew = Documents.Add 
Set tableNew = docNew.Tables.Add(Range:=Selection.Range, _ 
 NumRows:=3, NumColumns:=3) 
 
tableNew.Rows(1).SetLeftIndent LeftIndent:=InchesToPoints(0.5), _ 
 RulerStyle:=wdAdjustSameWidth

See also

Row Object

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.