如何设置VSTO 4.0先决条件?

时间:2012-01-13 17:34:51

标签: visual-studio-2010 deployment vsto windows-installer

我们使用的是Windows Installer / MSI 而不是 ClickOnce。

我们已经详细介绍了有关为我们创建Windows Installer的Microsoft文章 VSTO Outlook Addin:

Deploying a Visual Studio Tools for the Office System 3.0 Solution for the 2007 Microsoft Office System Using Windows Installer

没关系,但总是使用这些冗长,复杂,详细的脚本设置说明,知道什么是安全的,以适应我们自己的情况。

在我们的案例中,我们使用的是VS2010和VSTO4,其说明适用于VSTO3。因此,我们使用这些说明创建的启动器会抱怨缺少VSTO3。

我们需要改变什么?我们为VSTO4插入了什么?以下是文章的相关摘录:

6. In the Properties window, perform the following tasks.
   a) Set the value of (Name) to Search for VSTO 3.0 Runtime.
   b) Change the value of Property to VSTORUNTIME.
   c) Set the value of RegKey to Software\Microsoft\vsto runtime Setup\v9.0.21022
   d) Leave the Root property set to vsdrrHKLM.
   e) Change the Value property to Install.

7. In the Launch Conditions(ExcelAddInSetup) editor, select the Condition1 launch condition, right-click the condition and select Properties Window.

8. In the Properties window, perform the following tasks.
   a) Set (Name) to Verify VSTO 3.0 Runtime availability.
   b) Change the value of the Condition property to the following VSTORUNTIME = "#1"
   c) Leave the InstallURL property blank.
   d) Change the value of the Message property to The Visual Studio Tools for Office 3.0 Runtime is not installed. Please run Setup.exe.

这是在目标计算机上触发的最后一个错误(我们的自己的启动条件错误,如果你愿意的话)。

  

未安装用于Office 3.0运行时的Visual Studio工具。   请运行Setup.exe

1 个答案:

答案 0 :(得分:1)

这里有一个更新的指南:
http://msdn.microsoft.com/en-us/vsto/ff937654.aspx

相同的说明,但针对VSTO4进行了更新。