type Property
Retrieves the type of selection.
Syntax
HTML N/A Scripting [ sType = ] selection.type
Possible Values
sType String that specifies one of the following values:
none No selection/insertion point. text Text selection. control Control selection. The property is read-only with no default value.
Remarks
Example
This example uses the type property to create an alert that indicates the type of object selected by the user. If the user drags the mouse pointer over the text "Some text", the alert reads "Text". If the user drags the mouse pointer over the space to the right of the text, the alert reads "None".
Sample Code
<BODY onclick="alert(document.selection.type)"> Some text.
Applies To
[ Object Name ] Platform Version Win16: Win32: Mac: Unix: WinCE: Version data is listed when the mouse hovers over a link, or the link has focus.
HTML N/A Scripting selection
Did you find this topic useful? Suggestions for other topics? write us!
© 1999 microsoft corporation. all rights reserved. terms of use.