Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining


Gets the indexes of the first and last characters in a range of text that is highlighted in the current edit control.

BOOL GetHighlight(
     int* pichStart, 
     int* pichEnd
) const;



[out] pichStart

Zero-based index of the first character in the range of text that is highlighted.

[out] pichEnd

Zero-based index of the last character in the range of text that is highlighted.

true if this method is successful; otherwise, false.

This method sends the EM_GETHILITE message, which is described in the Windows SDK.

Header: afxwin.h

This control is supported in Windows Vista and later.

Additional requirements for this method are described in Build Requirements for Windows Vista Common Controls.

Community Additions

© 2015 Microsoft