ExtendSelection
Syntax
ExtendSelection [Character$]
Remarks
Performs one of the following actions:
- If extend mode is off, activates extend mode (in extend mode, actions that normally move the insertion point move the active end of the selection).
- If extend mode is already on, extends the selection to the next unit of text
(the progression is as follows: word, sentence, paragraph, section, entire document). - If Character$ is specified, extends the selection from the insertion point or the fixed end of the current selection (the end of the selection that does not move when you press SHIFT+an arrow key) to the next instance of that character without activating or deactivating extend mode.
You can use ExtendSelection with EditGoTo and EditFind to extend the selection to a specific location or piece of text. Use the Cancel statement to deactivate extend mode.
Example
This example selects all text from the insertion point to and including the bookmark "MyMark":
ExtendSelection
EditGoTo "MyMark"
Cancel
See Also
Cancel, ColumnSelect, ExtendMode(), ShrinkSelection