如何建立一个插件的多个Office程序

如何建立一个插件的多个Office程序

本文介绍了如何建立一个插件的多个Office程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想开发加载项为Office(如Outlook,Word和Excel)。在code将几乎相同。所不同的是只为检索文档(邮件的Outlook,用于Word,图形/图表Excel文档。

I want to develop addins for Office (Outlook,Word and Excel). The code will be almost the same. The difference is only for retrieve a document (mail for Outlook, document for Word,graphic/chart for Excel.

我应该开发3加载项,因此,我将有3个装置为我的用户。或者,我可以只开发1插件,并添加一个条件什么地方?

Should I develop 3 addins and therefore I will have 3 installations for my users. Or can I develop only 1 addin and add a condition somewhere?

推荐答案

是的,这是可能的。你可能需要3个不同的的AddIn 类,因为每个平台都有自己的格式和参数,你可能要偏离一些逻辑,虽然没有什么可以阻止你将三个附加-INS于一体。

Yes, that is possible. You possibly need 3 different AddIn classes, since every platform has it's own format and parameters and you might want to deviate some logic, though there is nothing to stop you integrating the three add-ins in one.

另一种方法是使只使用一般的办公组件类库,并包括图书馆到其他项目。

Another option is to make a class library that only uses the general Office assembly, and include that library into your other projects.

有关部署:您不能使用ClickOnce的开箱即用的,由于ClickOnce的仅支持每安装一个Office程序。你可以调整安装不过,因为MSDN上的这篇文章解释:的部署多个Office 2010。

For the deployment: you can't use ClickOnce out of the box for that, since ClickOnce only supports a single Office program per installation. You can tweak the installation though, as explained on this article on MSDN: Deploying Multiple Office 2010 Projects in One Package.

这篇关于如何建立一个插件的多个Office程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-31 09:00