Small company logo:
   History
 
Advertising banner:
 
 Field.SelLength
Home • Help • Customization Tools • FCAS • Language Reference • Field.SelLength
 
Purpose
Sets the length of the selected text in a text field.
If a starting point for the selection of text is not set with SelStart, the selected text begins at the first character.
Syntax
[Form].Field.SelLength (NumericExpression)
If the numeric expression is larger than the number of characters in the text buffer, SelLength selects all of the text in the field. If numeric expression is set to 0, the cursor is placed at the location specified by SelStart (or character 0 if SelStart is not called first) and no text is selected.
Example
Sub Click()
        ...
        StringField1002.SelLength(25)   'select the 1st 25 chars in StringField 1002
        StringField1002.SelLength(0)    '0 = no selection; place cursor at SelStart
        StringField1002.SelLength(5)    'select characters 7 - 12
        ...
End Sub