Udostępnij za pośrednictwem


How to: Publish an Office Solution by Using ClickOnce

You can publish (deploy) Office solutions by using the Publish Wizard or by using the Publish page of the Project Designer. For information about the differences, see Publishing Office Solutions by Using ClickOnce.

Applies to: The information in this topic applies to document-level projects and application-level projects for Microsoft Office 2010 and the 2007 Microsoft Office system. For more information, see Features Available by Office Application and Project Type.

Note

Your computer might show different names or locations for some of the Visual Studio user interface elements in the following instructions. The Visual Studio edition that you have and the settings that you use determine these elements. For more information, see Working with Settings.

link to video For a video version of this topic, see Video How to: Deploy an Office Solution by Using ClickOnce (2007 System).

To publish Office solutions by using the Publish Wizard

  1. On the Build menu, click Publish solutionName.

    The Publish Wizard appears.

  2. In the Specify the location to publish this application box, enter the path to the folder where you want the wizard to copy the solution files. It can be a local path (C:\foldername\foldername), a fully qualified path for a URL (HTTP or HTTPS), a UNC path (\\servername\foldername), or a relative path (publishfolder\).

    If you have Internet Information Services (IIS) installed on your development computer, the Specify the location to publish this application box displays https://localhost/project name/ by default. Otherwise, this box displays publish\ by default, which publishes the solution to the publish folder in the project directory.

    Note

    On Windows Vista and Windows 7, Visual Studio must be run as administrator to publish to IIS.

  3. Click Next.

  4. On the What is the default installation path on end user computers? page, select the option that describes where end users will find the deployed solution. Enter the fully qualified path to the folder, if a text box is available.

    Note

    If a path is specified here, the files in the publish folder must be copied to the installation location before users can install the solution. For more information, see How to: Change the Installation Path of an Office Solution.

  5. Click Finish.

    The Publish Wizard copies the Setup program, a deployment manifest that points to the latest version-specific deployment manifest, and the solution document (for document-level customizations) to the location you specified on the first page. It copies the assemblies, the version-specific application manifest, and the version-specific deployment manifest to a version-specific subdirectory under the Application Files folder in the publish folder.

  6. Copy the solution files to the installation location, if it is different from the publish location. The installation location is where end users will go to install the solution.

  7. Make changes to security settings so that each end user can run the solution, such as adding document locations to the Office trusted folder list. For more information, see Securing Office Solutions.

To publish Office solutions by using the Project Designer

  1. Select the project node in Solution Explorer, and then, on the Project menu, click Projectname Properties.

    The Project Designer appears.

  2. Click the Publish tab.

  3. In the Publishing Folder Location (web site, ftp server, or file path) box, enter the path to the folder where you want the Project Designer to copy the solution files. It can be a local path (C:\foldername\foldername), a fully qualified path to a URL (HTTP or HTTPS), a UNC path (\\servername\foldername), or a relative path (publishfolder\).

    If you have Internet Information Services (IIS) installed on your development computer, the Publishing Folder Location (website, ftp server, or file path) box displays https://localhost/project name/ by default. Otherwise, this box displays publish\ by default, which publishes the solution to the publish folder in the project directory.

    Note

    On Windows Vista and Windows 7, Visual Studio must be run as administrator to publish to IIS.

  4. In the Installation Folder URL box, enter the fully qualified path to the location where end users will find the deployed solution. If you are deploying to a CD or removable drive, leave this box blank.

    Note

    The installation location should only be filled out if the installation path for end users is known and will not change. If this location is set, the Setup program looks for the installation files in this location. For more information, see Publishing Office Solutions by Using ClickOnce.

  5. Click Prerequisites, and make any changes you want to the default settings. For more information, see Prerequisites Dialog Box.

    Note

    If you create a Microsoft Office 2010 solution that targets .NET Framework 4, you must select the Visual Studio 2010 Tools for Office Runtime in the Prerequisites Dialog Box.

  6. Click Updates, and specify how often you want each end user's customization to check for updates. If you are deploying by using a CD or removable drive, set this to Never check for updates. For an explanation of these configurable updates, see Publishing Office Solutions by Using ClickOnce.

  7. In the Publish Language list, select the language for the software license terms and displayed UI messages.

    Note

    The language setting does not change the language of the application or deployment manifest.

  8. In the Publish Version section, ensure that Automatically increment revision with each release is selected if you want the Project Designer to update the version numbering automatically. Otherwise, clear the check box and set the version number manually.

  9. Click Publish Now.

    The Project Designer copies the Setup program, a deployment manifest that points to the latest version-specific deployment manifest, and the solution document (for document-level customizations) to the location you specified as the publishing folder location. It copies the assemblies, the version-specific application manifest, and the version-specific deployment manifest to a version-specific subdirectory under the Application Files folder in the publish folder.

  10. Copy the solution files to the installation location, if it is different from the publish location. The installation location is where end users will go to install the solution.

  11. Make changes to security settings so that each end user can run the solution, such as adding document locations to the Office trusted folder list. For more information, see Securing Office Solutions.

See Also

Tasks

How to: Sign Office Solutions

Other Resources

Deploying Office Solutions

Deployment Overview (Office Development in Visual Studio)