ITextRange::Collapse method

Collapses the specified text range into a degenerate point at either the beginning or end of the range.

Syntax


HRESULT Collapse(
  [inlong bStart
);

Parameters

bStart [in]

Type: long

Flag specifying the end to collapse at. It can be one of the following.

ValueMeaning
tomStart or tomTrue

Range is collapsed to the start of the range. This is the default.

tomEnd or tomFalse

Range is collapsed to the end of the range.

 

Return value

Type: HRESULT

This method returns an HRESULT value. If successful, it returns S_OK. Otherwise, it returns S_FALSE.

Requirements

Minimum supported client

Windows Vista [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]

Header

Tom.h

DLL

Msftedit.dll

See also

Reference
ITextRange
Conceptual
Text Object Model

 

 

Show: