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

EM_SETTARGETDEVICE Message


The EM_SETTARGETDEVICE message sets the target device and line width used for WYSIWYG formatting in 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_SETTARGETDEVICE,     // message ID
   (WPARAM) wParam,     // = (WPARAM) () wParam;
   (LPARAM) lParam     // = (LPARAM) () lParam;
);

Parameters

wParam
Handle to a device context for the target device.
lParam
Line width to use for formatting.

Return Value

If the operation succeeds, the return value is a nonzero value.

If the operation fails, the return value is zero.


Message Information

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

See Also

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