Udostępnij za pośrednictwem


Deploying an Office Solution by Using Windows Installer (2007 System)

Applies to

The information in this topic applies only to the specified Visual Studio Tools for Office projects and versions of Microsoft Office.

Project type

  • Document-level projects

  • Application-level projects

Microsoft Office version

  • 2007 Microsoft Office system

For more information, see Features Available by Application and Project Type.

If you do not want to use the Publish Wizard or Publish page of the Project Designer to deploy your 2007 Microsoft Office system solutions, you can create a stand-alone installer program (.msi file) by using Windows Installer and distribute that file instead. The .msi file can be distributed by using Systems Management Server (SMS).

The process for distributing an installer file differs from the process for using the Publish Wizard or Publish page:

  • You must manually configure the required registry keys.

  • You can include additional components such as Visio stencils.

  • You can include more customized branding in your solution.

You must still use ClickOnce security to trust your solution, even if you do not use it to deploy the solution. For more information, see Security in Office Solutions (2007 System).

link to video For a related video demonstration, see Deploying Excel Document-level Customizations with Windows Installer and Deploying Excel Application-level Add-ins with Windows Installer.

Configuring Setup Projects

You can deploy your Office solution by using a Setup project. For more information, see How to: Create or Add a Setup Project. After adding a Setup project, you must configure your Setup project to include project output and to make your assembly discoverable to the Office application. Application-level add-ins use registry keys for discoverability. Document-level customizations use custom document properties.

Including Project Output

To configure your Setup project to include project output, you can add either the build or publish project output of your solution to your setup project. If you use the build project output, use only the files from the bin\release directory. Although the manifest files are in the same directory as the project output, the application manifest (.dll.manifest) and the deployment manifest (.vsto) must be added manually to the setup project. For more information, see Publishing Office Solutions (2007 System).

Setting Up the Development Computer

You can prepare your development computer by adding the Visual Studio Tools for Office runtime, .NET Framework, and other prerequisites to the Visual Studio bootstrapper packages directory. These directories contain XML files that describe how the prerequisite should be installed and any necessary error checking. For more information, see Adding Custom Prerequisites.

You can find code samples and deployment walkthroughs in the following whitepapers.

Application-Level Add-Ins

You must enable the Microsoft Office application to discover and load the add-in by creating registry keys. Add the registry keys that are listed in Registry Entries for Application-Level Add-Ins for the 2007 Microsoft Office system. For the Manifest registry key, append |vstolocal, which loads your add-in from any location (such as %ProgramFiles%), instead of from the ClickOnce cache.

Outlook form regions require an additional registry key that is also described in Registry Entries for Application-Level Add-Ins.

Document-Level Customizations

Document-level customizations do not use registry keys. Instead, the location of the deployment manifest is stored in custom document properties. For more information, see Custom Document Properties Overview.

The Visual Studio Tools for Office ClickOnce Publish Wizard updates the document properties to point to the customization assembly on a file share or web site. When you use Windows Installer, you must manually change the value of the _AssemblyLocation property to point to the deployment manifest as a custom action in your Setup project by using the ServerDocument class. For more information, see How to: Attach Managed Code Extensions to Documents (2007 System).

See Also

Concepts

Office Solution Prerequisites for Deployment (2007 System)

Other Resources

Deploying a Visual Studio Tools for the Office System 3.0 Solution for the 2007 Microsoft Office System Using Windows Installer (Part 1 of 2)

Deploying Visual Studio 2005 Tools for Office Second Edition Solutions Using Windows Installer (Part 1 of 2)

Change History

Date

History

Reason

July 2008

Added topic.

Adding deployment information.