TextRange.moveStart() (Method)

Relocates the start point of a TextRange.

Availability:

JScript - 3.0
Internet Explorer - 4.0
JavaScript syntax:IEmyTextRange.moveStart(aSelector)
IEmyTextRange.moveStart(aSelector, aCount)
Argument list:aCountIndicates how many times to iterate
aSelectorA rule selector

This works in almost the same way as the move() method but instead of collapsing the TextRange first, it just operates on the start point of the current text range. Then the keyword determines how the start point is indexed onwards or backwards.

This method has two arguments. The first argument indicates what to look for when adjusting the TextRange object. The second indicates how many times to apply that location search. A negative value indicates a backwards search. The start point is modified according to the rules determined by this keyword. If the second argument is omitted, it is assumed to be the value 1. The following keywords can be applied:

The character keyword causes the startpoint to be indexed onwards by a single character position.

The word keyword looks for the next word break in the document text.

The sentence keyword looks for the next full stop at the end of a sentence.

The textedit keyword moves the start point either to the beginning or end of the original selection.

This method returns an integer describing how many times it was able to move the start point.

Warnings: