PRB: Keystroke Problems in CView/CWnd WebBrowser ControlLast reviewed: January 2, 1998Article ID: Q165074 |
The information in this article applies to:
SYMPTOMSWhen the Web Browser control is embedded in a CView or CWnd class, keystrokes do not work properly. You may notice following symptoms:
CAUSEThis functionality in CView and CWnd classes is by design. The CView and Wnd classes do not carry the additional overhead necessary to forward these keyboard messages to children for processing. It is necessary to add this functionality to your derived class by using PreTranslateMessage.
RESOLUTIONOverride PreTranslateMessage for the parent of the Web Browser Control as follows:
BOOL CMyView::PreTranslateMessage(MSG* pMsg) { if(IsDialogMessage(pMsg)) return TRUE; else return CWnd::PreTranslateMessage(pMsg); } STATUSThis behavior is by design.
MORE INFORMATIONNormally, the Web Browser Control is embedded in a dialog box or CFormView. It is possible to dynamically create the control and embed it in a CView or CWnd class. The IEZoom sample illustrates a method of doing this. For additional information, please see the following article(s) in the Microsoft Knowledge Base:
ARTICLE-ID: Q156693 TITLE : IEZOOM.EXE Changes the Font Size of the Web Browser Control |
Additional query words: c view wnd
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |