共用方式為


ProjectOutputFile element

Applies to: yesVisual Studio noVisual Studio for Mac

Note

This article applies to Visual Studio 2017. If you're looking for the latest Visual Studio documentation, see Visual Studio documentation. We recommend upgrading to the latest version of Visual Studio. Download it here

Represents the output of a separate project to include with the project item when it is deployed to SharePoint.

Syntax

<ProjectOutputFile ProjectId = "GUID of the project"
    ProjectPath = "Relative path of the project"
    Target = "Deployment path of the project output"
    Type = "Type of deployment for the project output" />

Type

ProjectOutputFileType

Attributes and elements

The following sections describe attributes, child elements, and parent elements.

Attributes

Attribute Description
ProjectId Required xs:string attribute.

The GUID of the dependent project that has the output you want to include. This corresponds to the ProjectGuid element in the dependent project file.
ProjectPath Required xs:string attribute.

The relative path, including the project file name, of the dependent project that has the output you want to include. This path is relative to the root folder of the SharePoint project that contains the SharePoint project item.
Target Optional xs:string attribute.

The path where the dependent project output is to be deployed on the SharePoint server, relative to the deployment root folder. The deployment root folder is determined by the deployment type specified by the Type attribute.

For more information, see the descriptions for the Deployment Path and Deployment Root properties of SharePoint project items in Develop SharePoint solutions.
Type Required xs:string attribute.

The type of deployment to use for the output of the dependent project. For more information about the possible values, see the description for the Deployment Type property of SharePoint project items in Develop SharePoint solutions.

Child elements

None.

Parent elements

Element Description
Files Specifies the files to include with the SharePoint project item when it is deployed to SharePoint.

Remarks

Use the ProjectOutputFile element to include the output of a project in the deployment of the SharePoint project item. You can specify a different project, or the same project that contains the project item. For more information, see Provide packaging and deployment information in project items.

Element information

Property Value
Namespace http://schemas.microsoft.com/VisualStudio/
2010/SharePointTools/SharePointProjectItemModel
Schema name SharePoint Project Item Schema
Validation file ProjectItemModelSchema.xsd
Can be empty No

See also