Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

PreTranslateAccelerator in ATL ActiveX control

95 views
Skip to first unread message

Maciej Mróz

unread,
Aug 21, 2003, 10:18:46 AM8/21/03
to
I have ATL ActiveX control that usually is embedded inside Internet Explorer
on html page. I have no problems running control in that configuration. I
use PreTranslateAccelerator function and it works as i should. Recently i
have written WTL application that hosts WebBrowser control, and that
WebBrowser control hosts my ActiveX control mentioned earlier. With that
application my control's PreTranslateAccelerator function _never_ gets
called!
Obviously only thing that differs is application that hosts WebBrowser but
after looking through code I have no idea what may be the cause of this. I
tried even explicit SendMessage to WebBrowser's HWND obtained through HWND
property and it was ignored and never made its way down to control's
PreTranslateAccelerator :( Any ideas?

Maciej Mróz


Igor Tandetnik

unread,
Aug 21, 2003, 12:18:53 PM8/21/03
to
"Maciej Mróz" <mm...@student.uci.agh.edu.pl> wrote in message
news:e9ODy7%23ZDH...@TK2MSFTNGP09.phx.gbl...

> I have ATL ActiveX control that usually is embedded inside Internet
Explorer
> on html page. I have no problems running control in that
configuration. I
> use PreTranslateAccelerator function and it works as i should.
Recently i
> have written WTL application that hosts WebBrowser control, and that
> WebBrowser control hosts my ActiveX control mentioned earlier. With
that
> application my control's PreTranslateAccelerator function _never_ gets
> called!

See http://www.microsoft.com/mind/0499/faq/faq0499.asp
--
With best wishes,
Igor Tandetnik

"For every complex problem, there is a solution that is simple, neat,
and wrong." H.L. Mencken


Maciej Mróz

unread,
Aug 21, 2003, 1:49:10 PM8/21/03
to
"Igor Tandetnik" <itand...@mvps.org> wrote in message
news:#a8EMAAa...@TK2MSFTNGP09.phx.gbl...

> "Maciej Mróz" <mm...@student.uci.agh.edu.pl> wrote in message
> news:e9ODy7%23ZDH...@TK2MSFTNGP09.phx.gbl...
> > I have ATL ActiveX control that usually is embedded inside Internet
> Explorer
> > on html page. I have no problems running control in that
> configuration. I
> > use PreTranslateAccelerator function and it works as i should.
> Recently i
> > have written WTL application that hosts WebBrowser control, and that
> > WebBrowser control hosts my ActiveX control mentioned earlier. With
> that
> > application my control's PreTranslateAccelerator function _never_ gets
> > called!
>
> See http://www.microsoft.com/mind/0499/faq/faq0499.asp

Thanks for the link, that clarified a lot to me. I got to the idea of
calling TranslateAccelerator manually by myself after some searching through
ATL headers, but haven't managed to give it a try today. I'll definitely do
it tomorrow, especially when now I know this is the right way of doing it.


0 new messages