The information in this article applies to:
SYMPTOMSWhen editing labels in a TreeView control, you should be able to press the ESC key to cancel the changes or press the ENTER key to accept the changes. However, when the TreeView control is contained in a dialog box, IsDialogMessage processes the ESC and ENTER keystrokes and does not pass them on to the edit control created by the TreeView control, so the keystrokes have no effect. CAUSEThe TreeView control creates and subclasses the edit control used for in-place editing. The subclass procedure does not process the WM_GETDLGCODE and WM_CHAR messages for the edit control properly. RESOLUTION
To work around the problem, subclass the edit control and return
DLGC_WANTALLKEYS in response to the WM_GETDLGCODE message. Then process the
WM_CHAR messages for VK_ESCAPE and VK_RETURN.
Additional query words:
Keywords : kbCtrl kbNTOS kbTreeView kbGrpUser kbWinOS |
Last Reviewed: February 2, 2000 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |