Syntax
SelectCurWord
Remarks
Selects the entire word containing the insertion point or selection. Whereas double-clicking a word selects both the word and the trailing space (if any), SelectCurWord does not select the trailing space. If the selection is larger than
a word when SelectCurWord is run, an error occurs.
Example
This example defines the variable a$ as the characters in the word containing the insertion point. If there is a selection, the first instruction cancels it, so in effect, a$ is defined as the first word in the selection.
If SelType() = 2 Then SelType 1 'Cancel selection, if any SelectCurWord a$ = Selection$()
See Also
SelectCurSentence, WordLeft, WordRight