Hi All,

If I place a com "wrapped" WebBrowser control on a form - it works fine if
NOT and MDI child.
If it is an MDI child, then the other controls (text boxes for example) -
will not take mouse input correctly, etc.

I researched and found a fix to call form.Activate() if WM_MOUSEACTIVATE is
called - but it did not work.
I also found a fix to additionally subclass the WebBrowser to call Focus() -
which did not work.

If you switch to a different MDI child, and then switch back - everything
then works correctly.

If you switch to a different application, and then switch back - everything
then works correctly.


This is very frustrating - I have not found any useful info so far.
- Again - the Activate() on WM_MOUSEACTIVATE does not work

Thanks in advance for any help.

Tom

Re: WebBrowser in MDI form messes with other controls focus by TkPins

TkPins
Mon Jan 24 20:28:58 CST 2005

- UPDATE -

I implemented a workaround that I really don't like, but it works.

In the forms Load event, I Show() another form (very small) and then Close()
it immediately (almost not noticeable flash).

By switch forms, and then back the problem goes away.

-- Please - if anyone has a better solution, please let me know.

Thanks,
Tom



"TkPins" <tXkpinXsX@XtcksoftX.com> wrote in message
news:_ZmdnYvsdYoOPmjcRVn-1Q@comcast.com...
> Hi All,
>
> If I place a com "wrapped" WebBrowser control on a form - it works fine if
> NOT and MDI child.
> If it is an MDI child, then the other controls (text boxes for example) -
> will not take mouse input correctly, etc.
>
> I researched and found a fix to call form.Activate() if WM_MOUSEACTIVATE
is
> called - but it did not work.
> I also found a fix to additionally subclass the WebBrowser to call
Focus() -
> which did not work.
>
> If you switch to a different MDI child, and then switch back - everything
> then works correctly.
>
> If you switch to a different application, and then switch back -
everything
> then works correctly.
>
>
> This is very frustrating - I have not found any useful info so far.
> - Again - the Activate() on WM_MOUSEACTIVATE does not work
>
> Thanks in advance for any help.
>
> Tom
>
>