ISharePointProjectMemberReferenceCollection.Add Method (String, Guid)
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Creates a reference to a project item and adds it to this collection.
Namespace: Microsoft.VisualStudio.SharePoint
Assembly: Microsoft.VisualStudio.SharePoint (in Microsoft.VisualStudio.SharePoint.dll)
Syntax
'Declaration
Function Add ( _
projectPath As String, _
itemId As Guid _
) As ISharePointProjectMemberReference
ISharePointProjectMemberReference Add(
string projectPath,
Guid itemId
)
Parameters
projectPath
Type: System.StringThe path of the project.
itemId
Type: System.GuidThe ID of the project item.
Return Value
Type: Microsoft.VisualStudio.SharePoint.ISharePointProjectMemberReference
The project item reference added to the collection.
Remarks
This path should be relative to the current project. That is, the project to which the reference, not the referenced item, belongs.
If the path is nulla null reference (Nothing in Visual Basic) or empty, then the current project is assumed.
Paths can be absolute, but it is not recommended because it risks tying a solution to a specific development system.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.