TextRange.Text Property

PowerPoint Developer Reference

Returns or sets a String that represents the text contained in the specified object. Read/write.

Syntax

expression.Text

expression   A variable that represents a TextRange object.

Return Value
String

Example

This example sets the text and font style for the title on slide one in the active presentation.

Visual Basic for Applications
  Set myPres = Application.ActivePresentation
With myPres.Slides(1).Shapes.Title.TextFrame.TextRange
    .Text = "Welcome!"
    .Font.Italic = True
End With

See Also