MSDN Home >  MSDN Library >  User Interface Design and Development >  Windows Shell >  Windows Controls >  Individual Control Information >  Rich Edit Controls > 

EM_GETTEXTRANGE Message


The EM_GETTEXTRANGE message retrieves a specified range of characters from a rich edit control.

Syntax

To send this message, call the SendMessage function as follows.
lResult = SendMessage(     // returns LRESULT in lResult
   (HWND) hWndControl,     // handle to destination control
   (UINT) EM_GETTEXTRANGE,     // message ID
   (WPARAM) wParam,     // = (WPARAM) () wParam;
   (LPARAM) lParam     // = (LPARAM) () lParam;
);

Parameters

wParam
This parameter is not used; it must be zero.
lParam
Pointer to a TEXTRANGE structure that specifies the range of characters to retrieve and a buffer to copy the characters to.

Return Value

The message returns the number of characters copied, not including the terminating null character.


Message Information

HeaderDeclared in Richedit.h
Minimum operating systems Windows 95, Windows NT 4.0

See Also

Rich Edit Controls, TEXTRANGE
 Contact Us   |  E-Mail this Page   |  MSDN Flash Newsletter
 © 2003 Microsoft Corporation. All rights reserved.   Terms of Use  Privacy Statement   Accessibility