ITextRange::GetEnd method

Gets the end character position of the range.

Syntax


HRESULT GetEnd(
  long *pcpLim
);

Parameters

pcpLim

Type: long*

The end character position.

Return value

Type: HRESULT

The method returns an HRESULT value. If the method succeeds, it returns S_OK. If pcpLim is null, the method fails and it returns E_INVALIDARG.

Remarks

Although a pointer to a range remains valid when the text is edited, this is not the case for the character position. A character position is volatile; that is, it becomes invalid as soon as text is inserted or deleted before the character position. Be careful about using methods that return character position values, especially if the values are to be stored for any duration.

This method is similar to the ITextRange::GetStart method which gets the start character position of the range.

Requirements

Minimum supported client

Windows 2000 Professional [desktop apps only]

Minimum supported server

Windows 2000 Server [desktop apps only]

Header

Tom.h

DLL

Msftedit.dll

See also

Reference
ITextRange
GetStart
SetEnd
Conceptual
Text Object Model

 

 

Community Additions

ADD
Show:
© 2014 Microsoft