Help Center

CTextRange2.GetSubrangemethod

Retrieves a subrange in a range.

Windowsmethoddocumented

Syntax

FUNCTION GetSubrange (BYVAL iSubrange AS LONG, BYVAL pcpFirst AS LONG PTR, BYVAL pcpLim AS LONG PTR) AS HRESULT

Parameters

NameDescription
iSubrangeThe subrange index.
pcpFirstThe character position for the start of the subrange.
pcpLimThe character position for the end of the subrange.

Return value

If the method succeeds, it returns NOERROR. Otherwise, it returns an HRESULT error code.

Description

Retrieves a subrange in a range.

Remarks

Subranges are selected as follows.

See GetCount for the count of subranges not including the active subrange.

Reference

  • Defined in AfxNova/CTextRange2.inc:1028
  • Documented in Windows/WIndows Controls/RichEdit/CTextRange2 Class.md
  • Topic: CTextRange2 Class