please dont rip this site
The Selection Object

The Selection object is Internet Explorer 4.0 specific and is an object that represents any currently selected section of a document. Sections of a document are typically selected by the user holding down a mouse button and dragging the mouse, but can also be created by scripts using the select method on a Text Range Object.

Properties
type
The type property is read-only and can be one of two values ("None" or "Text"). If the user has selected some text and/or other elements in a document, then the type property will return "Text", otherwise if no selection has been made, the type property will return "None".

Methods
clear
The clear method can be used to remove the current text selection from the document. This is going to prove useful for people wanting to build WYSIWYG HTML editors based on Internet Explorer 4.0. Coupled with methods like the execCommand method (see the Document Object) to insert HTML elements, a new breed of editors will start to appear based entirely on the Internet Explorer 4.0 HTML rendering engine.

createRange
The createRange method creates a Text Range object from the current active selection. This can then be manipulated through the properties, methods and events of the TextRange object.

empty
The empty method deselects the current selection, sets the selection type to "none", and sets the item property to null. The visual effect of the empty method is deselection of the text (i.e. its highlight is removed) Note : The two methods will only work in the text section below and at the time of writing, using the empty method caused the document to scroll to the top.

For example:

Select your method choice from the radio buttons below, then select any of this text (left-mouse button and drag) and press the right-mouse button to clear or empty the selection.


Events
The Selection Object has no events.

See also:


file: /Techref/language/html/ib/Scripting_Reference/selo.htm, 4KB, , updated: 2004/3/1 15:47, local time: 2017/12/17 06:22,
TOP NEW HELP FIND: 
54.92.194.75:LOG IN

 ©2017 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?
Please DO link to this page! Digg it! / MAKE! / 

<A HREF="http://www.piclist.com/techref/language/html/ib/Scripting_Reference/selo.htm"> The Selection object</A>

After you find an appropriate page, you are invited to your to this massmind site! (posts will be visible only to you before review) Just type in the box and press the Post button. (HTML welcomed, but not the <A tag: Instead, use the link box to link to another page. A tutorial is available Members can login to post directly, become page editors, and be credited for their posts.


Link? Put it here: 
if you want a response, please enter your email address: 
Attn spammers: All posts are reviewed before being made visible to anyone other than the poster.
Did you find what you needed?

  PICList 2017 contributors:
o List host: MIT, Site host massmind.org, Top posters @20171217 RussellMc, Van Horn, David, Sean Breheny, James Cameron, alan.b.pearce, IVP, Neil, Bob Blick, David C Brown, John Gardner,
* Page Editors: James Newton, David Cary, and YOU!
* Roman Black of Black Robotics donates from sales of Linistep stepper controller kits.
* Ashley Roll of Digital Nemesis donates from sales of RCL-1 RS232 to TTL converters.
* Monthly Subscribers: Gregg Rew. on-going support is MOST appreciated!
* Contributors: Richard Seriani, Sr.
 

Welcome to www.piclist.com!

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

  .