Selection.Expand method (Word)
Expands the specified range or selection. Returns the number of characters added to the range or selection. Long.
expression Required. A variable that represents a Selection object.
|Unit||Optional||Variant||A WdUnits constant that represents the unit by which to expand the range. The default value is wdWord.|
This example capitalizes the first character in the selection and then expands the selection to include the entire sentence.
With Selection .Characters(1).Case = wdTitleSentence .Expand Unit:=wdSentence End With
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.