Edit_SetReadOnly

Edit_SetReadOnly macro

Sets or removes the read-only style (ES_READONLY) of an edit or rich edit control. You can use this macro or send the EM_SETREADONLY message explicitly.

Syntax


BOOL Edit_SetReadOnly(
   HWND hwndCtl,
   BOOL fReadOnly
);

Parameters

hwndCtl

Type: HWND

A handle to the control.

fReadOnly

Type: BOOL

TRUE to set the control to read-only; FALSE to remove the read-only style.

Return value

TRUE if the operation succeeds; otherwise FALSE.

Remarks

For more information, see EM_SETREADONLY.

Requirements

Minimum supported client

Windows Vista [desktop apps only]

Minimum supported server

Windows Server 2003 [desktop apps only]

Header

Windowsx.h

 

 

Show:
© 2016 Microsoft