ONKEYPRESS Event does not bubble up

From: Santino (sankumar_nt_at_yahoo.com)
Date: 12/16/04

  • Next message: Tim Bücker: "IWebBrowser2: Navigate2 ignored"
    Date: 15 Dec 2004 17:28:02 -0800
    
    

    Hi,

    I'm sinking the HTMLTextContainerEvents2 for the <body> of the
    document. I can trap the DISPID_HTMLELEMENTEVENTS2_ONKEYPRESS event,
    but when i trap it, it stops inserting the text in the document. I'm
    not cancelling the event. Here is my event code -

    void __stdcall OnKeyPress( IHTMLEventObj *pEvtObj )
    {
    VARIANT var;
    var.vt = VT_BOOL;
    var.boolVal = VARIANT_FALSE;

    pEvtObj->put_returnValue(var);
    pEvtObj->put_cancelBubble(VARIANT_TRUE);

    ...
    }

    If you have faced this issue, or have any information, please pass it
    on.

    Thanks


  • Next message: Tim Bücker: "IWebBrowser2: Navigate2 ignored"