ActiveX Control Fundamentals
来源:互联网 发布:matlab 数组 差分 编辑:程序博客网 时间:2024/05/16 17:12
From http://www.pluralsight.com/articlecontent/cpprep0199.htm:
Here we are, eight functions later, and we have an ActiveX control which can be embedded in any control container. This doesn't mean that you shouldn't reach for your nearest C++ library the next time you need to implement a control, but hopefully you have a better perspective on what that library is doing for you, and where to look when things don't behave as you expect.
It should be noted that the ActiveX support in Visual C++ (ATL and MFC) is much more than this simple implementation
From http://community.csdn.net/expert/Topicview2.asp?id=4868028
我一直搞不清楚,到底我创建的控件窗口在IE窗口中的位置是由我来管理还是由IE来管理,其实这根本不用我来操心。
我一直以为是我只负责现实接口,容器主动来找接口,所以我一直觉得很奇怪,为什么IE没来找IOleInPlaceObject接口。现在发现其实不然,有的时候是要我来通知容器来拿接口的,IOleInPlaceObject就是这种情况。
我在DoVerb收到OLEIVERB_INPLACEACTIVATE时,首先当然是创建我的控件窗口。然后,是关键一步,通过容器的IOleClientSite接口找到IOleInPlaceSite接口,然后调用IOleInPlaceSite->OnInPlaceActivate();这样IE就会来找IOleInPlaceObject接口了。在IOleInPlaceObject的GetWindow中我把我创建的控件窗口返回给容器,就这样,我的控件窗口就会归容器管辖,拖动滚动条时容器会根据情况移动我的控件窗口,根本不用我操心了。
- ActiveX Control Fundamentals
- ActiveX Control Fundamentals
- Common Control Fundamentals
- Common Control Fundamentals
- 支持ActiveX Control
- ActiveX Control Tutorial
- 自动激活activex control
- 自动激活 activex control
- MFC Activex Control
- Dissect ActiveX Control Safety
- Barcode ActiveX Control & DLL
- Graph ActiveX Control Samples [CodeProject]
- webbrowser control activex 初接触
- Reloading an ActiveX control error
- JavaScript Interactive with ActiveX Control
- Debug ActiveX Control Using VS2010
- 2D Graph ActiveX Control
- Postel ActiveX Control支持Postel的ActiveX控件
- 异步消息的传递-回调机制
- 九月第一贴,纪念大事件
- 数据封装之我见(2006-09-15)
- Afer one week affort for Java
- Q:实现IContextMenu出现C2787错误:“IContextMenu”:没有与该对象关联的GUID
- ActiveX Control Fundamentals
- 魔兽网游盗号木马文件 s.exe 的一点分析
- 看OO理论书籍的收获
- 酒不醉人人自醉
- Detect Input Method Changes
- Regsvr32命令的妙用
- 如何编写测试用例?
- Yeah!新家^.^
- net程序员面试笔试题目集合