IndentLevel Property

Microsoft Excel Visual Basic

Show All

IndentLevel Property

       

IndentLevel property as it applies to the Style object.

Returns or sets the indent level for the style. Read/write Long.

expression.IndentLevel

expression   Required. An expression that returns a Style object.

IndentLevel property as it applies to the CellFormat and Range objects.

Returns or sets the indent level for the cell or range. Can be an integer from 0 to 15. Read/write Variant.

expression.IndentLevel

expression   Required. An expression that returns one of the above objects.

Remarks

Using this property to set the indent level to a number less than 0 (zero) or greater than 15 causes an error.

Example

As it applies to the CellFormat and Range objects.

This example increases the indent level to 15 in cell A10.

With Range("A10")
    .IndentLevel = 15
End With