Article ID: 187988 - Last Review: November 21, 2006 - Revision: 6.1 The TAB key, arrow keys, and accelerator keys do not work as expected when an ActiveX control is the parent window of a modeless dialog box or of a propertysheet window
This article was previously published under Q187988 On This PageSYMPTOMS When an ActiveX control is the parent window of a modeless
dialog box or propertysheet window, the TAB key, arrow keys, and accelerator
keys don't work as expected. The TAB key doesn't move input focus from one
control to another. Pressing the arrow keys or accelerator keys in the modeless
dialog box or propertysheet window has no effect. CAUSE The problem is the ActiveX control doesn't own the message
pump. The message pump is owned by the container application. Therefore, all
the keystroke messages are taken by the container application and not
dispatched to the modeless dialog box or propertysheet window. The problem does not occur with a modal dialog box/propertysheet window because the message pump is owned by the dialog box manager, and it takes care of handling all keystroke messages. RESOLUTION Install a Windows WH_GETMESSAGE hook for the modeless
dialog box/propertysheet derived class to allow it to intercept keystrokes and
handle accelerators. STATUS This behavior is by design. MORE INFORMATION The following sample shows a way to install the Windows
message hook to a modeless CPropertySheet-derived class: Sample CodeSteps to Reproduce the Problem
REFERENCES (c) Microsoft Corporation 1998, All Rights Reserved.
Contributions by Yeong-Kah Tam, Microsoft Corporation. APPLIES TO
| Other Resources Other Support Sites
CommunityArticle Translations
|






Windows Live
Facebook
Twitter
Linkedin
Digg it
Yahoo
Delicious
StumbleUpon
Yammer
Reddit
Technorati
FriendFeed
Email
Back to the top