Edit

Share via


Ruler2 object (Office)

Represents the ruler for the text in the specified shape or for all text in the specified text style. Contains tab stops and the indentation settings for text outline levels.

Remarks

Use the Ruler2 property of the TextFrame2 object to return the Ruler2 object that represents the ruler for the text in the specified shape.

Use the TabStops2 property to return the TabStops2 object that contains the tab stops on the ruler.

Use the Levels property to return the RulerLevels2 object that contains the indentation settings for text outline levels.

Example

The following example sets a left-aligned tab stop at 2 inches (144 points) and sets a hanging indent for the text in object two on slide one in the active PowerPoint presentation.

With ActivePresentation.Slides(1).Shapes(2).TextFrame2.Ruler2 
 .TabStops2.Add ppTabStopLeft, 144 
 .Levels(1).FirstMargin = 0 
 .Levels(1).LeftMargin = 36 
End With 

See also

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.