Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

collapse method

Collapses (or removes) a range by moving the insertion point to the beginning or end of the current range.

Document Object Model (DOM) Level 2 Traversal and Range Specification, Section 2.13Internet Explorer 9

Syntax

var retval = Range.collapse(toStart);

Parameters

toStart [in]

Type: Boolean

Specifies one of the following values:

true

Default. Moves the insertion point to the beginning of the range.

false

Moves the insertion point to the end of the range.

Return value

Type: HRESULT

This method can return one of these values.

Return codeDescription
S_OK

The operation completed successfully.

InvalidStateError

detach has been invoked on the object.

 

Standards information

See also

Range
collapsed

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.