Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
inet
active_desktop
active_scrptng
asp.components
asp.db
asp.general
comctl32
comp.packaging
components.dev
dbweb
dhtml_editing
docobjects
html_authoring
html_objmodel
iis
iis.ftp
iis.security
iis.smtp_nntp
indexserver
misc
mshtml_hosting
scripting.jscript
scripting.vbscript
sdk_setup
shell_objmodel
urlmonikers
webbrowser_ctl
wininet
  
 
date: Mon, 30 Jun 2008 00:05:28 -0700 (PDT),    group: microsoft.public.inetsdk.programming.webbrowser_ctl        back       


How to solve falsh problem when I use CAxWindow / CAxHostWindow to host WebBrowser control   
Hi, everyone.

I use CAxWindow to host a WebBrowser control. When loading a page
which contains a Flash movie, the movie fails to respond to mouse
events except the first one.

I searched and found that many people encountered this problem, but
mostly on .NET framework. The following is a solution:

>>Symptoms
>>When a .NET 2.0 application uses the System.Windows.Forms.WebBrowser control to load a page which contains a Flash movie, the movie may fail to respond to mouse events.

>>Cause
>>The WebBrowserBase.WndProc method sets the focus to the WebBrowser control when a mouse event is received.

>>Workaround
>>Create a new control derived from the WebBrowser control, and override the WndProc method:

>>using System;
>>using System.Windows.Forms;

>>public class WebBrowserEx : WebBrowser
>>{
>>    public WebBrowserEx()
>>    {
>>    }
>>
>>    protected override void WndProc(ref Message m)
>>    {
>>        switch (m.Msg)
>>        {
>>            case 0x021:
>>            case 0x201:
>>            case 0x204:
>>            case 0x207:
>>                base.DefWndProc(ref m);
>>                return;
>>        }

>>        base.WndProc(ref m);
>>    }
>>}

I am not familiar with .NET. It would be deeply appreciated if
somebody tells me how to do the same thing in my code...

Thanks very much!!
date: Mon, 30 Jun 2008 00:05:28 -0700 (PDT)   author:   yuzhu.shen

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us