COM加载项应该有消息循环吗? [英] Should COM Add-Ins have a Message Loop?
问题描述
我的环境: Visual Studio 2010,Office 2010。
我正在为Excel,Word和PowerPoint编写COM加载项。 我正在使用ATL / COM和C ++编写插件,因为我知道它最好,我需要很长时间才能加速C#或VSTO。
My问题是COM加载项是否需要消息循环?
如果是这样,我将如何实现一个?
到目前为止,我只见过一个实现
http://www.codeproject.com/Articles/12680/How-to-Use-the-IMessageFilter ,我不确定这是否适用于COM Add -Ins for Office。
您好TSRACT,
感谢您在MSDN论坛。
我建议你更明确地宣布你的目标。根据我的经验,我们不会在外接程序开发中使用Message Loop。但是,如果你有特殊的要求,我不会用它是否会被使用。
祝你有个美好的一天,
Tom
My environment: Visual Studio 2010, Office 2010.
I am writing COM Add-Ins for Excel, Word, and PowerPoint. I am using ATL/COM and C++ to write the Add-In, simply because I know it best and it will take too long for me to come upto speed on C# or VSTO.
My question is does the COM Add-In require a Message Loop?
If so, how would I implement one?
To date I've only seen one implementation
http://www.codeproject.com/Articles/12680/How-to-Use-the-IMessageFilter, and I'm not sure if that would apply to COM Add-Ins for Office as well.
Hi TSRACT,
Thanks for posting in the MSDN Forum.
I would recommend you declear your goal more clearly. It's based on my experience that we will not use Message Loop in Add-in development. However I not user whether it will be used if you have specifical requirst.
Have a good day,
Tom
这篇关于COM加载项应该有消息循环吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!