Share via


ISharePointProjectOutputReferenceCollection.Add Method (String, DeploymentType)

Adds an output reference to the project. The reference is added as a build dependency to the current project and included as a part of the SharePoint project item.

Namespace:  Microsoft.VisualStudio.SharePoint
Assembly:  Microsoft.VisualStudio.SharePoint (in Microsoft.VisualStudio.SharePoint.dll)

Syntax

'Declaration
Function Add ( _
    projectFullPath As String, _
    deploymentType As DeploymentType _
) As ISharePointProjectOutputReference
ISharePointProjectOutputReference Add(
    string projectFullPath,
    DeploymentType deploymentType
)

Parameters

  • projectFullPath
    Type: String

    The project to be added as a reference. The project should be loaded in the solution for this method to work correctly.

Return Value

Type: Microsoft.VisualStudio.SharePoint.ISharePointProjectOutputReference
The reference that was added.

Exceptions

Exception Condition
ArgumentNullException

Occurs if the parameter projectFullPath is nulla null reference (Nothing in Visual Basic).

ArgumentException

Occurs if the parameter projectFullPath is nulla null reference (Nothing in Visual Basic) or no corresponding project could be found

.NET Framework Security

See Also

Reference

ISharePointProjectOutputReferenceCollection Interface

Add Overload

Microsoft.VisualStudio.SharePoint Namespace