IE 怎么响应 ActiveX控件产生的 事件?

bbasd88 2003-07-08 05:50:02
我用MFC写了一个ActiveX 控件,在IE 中调用控件的方法都能成功。

可控件的事件却没法响应成功。

网页的脚本代码是由 ActiveX Control Pad 生成的。

当控件有事件时,VC的调试窗口就会有:
constructing COleException, scode = E_UNEXPECTED ($8000FFFF).
的Warning 。

请问要怎么样,才能使ActiveX 控件的事件,能在IE的响应?

...全文
96 8 打赏 收藏 转发到动态 举报
写回复
用AI写文章
8 条回复
切换为时间正序
请发表友善的回复…
发表回复
蒋晟 2004-01-12
  • 打赏
  • 举报
回复
换一种通讯方式,或者改写成有窗口的控件
zhangcrony 2004-01-12
  • 打赏
  • 举报
回复
不懂﹐幫忙UP
freeshoot 2004-01-12
  • 打赏
  • 举报
回复
up
lop5712 2004-01-12
  • 打赏
  • 举报
回复
我在下面的帖子中说明了原因,楼主可参考一下
http://expert.csdn.net/Expert/topic/2650/2650433.xml?temp=.6281244
freeshoot 2004-01-11
  • 打赏
  • 举报
回复
老问题,新提问:
对于“MFC要做成可显示窗口的,并改用消息通知。”的确可以在消息响应函数中FireSomeEvent().
但是我想做在IE中运行时不显示窗口的MFC ActiveX控件
(设置OLEMISC_INVISIBLEATRUNTIME),发消息就会失败,我该怎么做呢?

希望高手点拨一二。
bbasd88 2003-07-15
  • 打赏
  • 举报
回复
MFC要做成可显示窗口的,并改用消息通知。
ATL不知怎么做。(不想在运行时显示窗口)
蒋晟 2003-07-09
  • 打赏
  • 举报
回复
Knowledge Base
Fireev.exe Fires Events from a Second Thread
This article was previously published under Q157437

MFC-based ActiveX controls typically fire their events from the same thread that implements the sink interface of the container that the events are being fired to.

Sometimes, it is desirable to start a second thread in an ActiveX control that will fire events to the container. Because MFC ActiveX controls use the Apartment-threading model, special consideration must be taken when firing events from a secondary thread.

see

http://download.microsoft.com/download/vc60pro/File/1/NT4/EN-US/Fireev.exe
bbasd88 2003-07-09
  • 打赏
  • 举报
回复
ActiveX 中的一工作线程,不定时的产生事件 IE无法响应。
不是线程产生的事件,IE就能响应,求解啊。

3,245

社区成员

发帖
与我相关
我的任务
社区描述
ATL,Active Template Library活动(动态)模板库,是一种微软程序库,支持利用C++语言编写ASP代码以及其它ActiveX程序。
社区管理员
  • ATL/ActiveX/COM社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧