Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

selectionEnd property

Gets or sets the end position or offset of a text selection.

HTML5 A vocabulary and associated APIs for HTML and XHTML, Section 7.6.2

 

Syntax

JavaScript

p = object.selectionEnd

 

Property values

Type: Integer

The end position of the text selection.

Standards information

Remarks

If you do not select text, selectionEnd returns the offset of the character that immediately follows the text cursor or caret.

See also

HTMLInputElement
input type=email
input type=number
input type=range
input type=search
input type=tel
input type=text
input type=url
textArea

 

 

Show:
© 2015 Microsoft