ComReferenceNode Constructor (ProjectNode, VSCOMPONENTSELECTORDATA)

Initializes a new instance of a ComReferenceNode for a given root project node and a VSCOMPONENTSELECTORDATA structure that refers to a COM component, initializing the reference node's properties.

Namespace:  Microsoft.VisualStudio.Package
Assembly:  MPF.Project.NonShipping (in MPF.Project.NonShipping.dll)

Syntax

'宣言
Public Sub New ( _
    root As ProjectNode, _
    selectorData As VSCOMPONENTSELECTORDATA _
)
'使用
Dim root As ProjectNode
Dim selectorData As VSCOMPONENTSELECTORDATA

Dim instance As New ComReferenceNode(root, selectorData)
public ComReferenceNode(
    ProjectNode root,
    VSCOMPONENTSELECTORDATA selectorData
)
public:
ComReferenceNode(
    ProjectNode^ root, 
    VSCOMPONENTSELECTORDATA selectorData
)
public function ComReferenceNode(
    root : ProjectNode, 
    selectorData : VSCOMPONENTSELECTORDATA
)

Parameters

Exceptions

Exception Condition
[System.NotSupportedException]

selectorData is not of type VSCOMPONENTTYPE_Project or VSCOMPONENTTYPE_ComPlus (i.e. a COM project).

[System.ArgumentException]

The registry path for the COM component is null or empty.

Remarks

This method sets the COM reference node's name, GUID, and major/minor version numbers from the selector data, and the LCID to [System.Globalization.CultureInfo.InvariantCulture]. The GUID must refer to a registered type library. This method sets the installed path from the registry entry for the COM component.

Permissions

See Also

Reference

ComReferenceNode Class

ComReferenceNode Members

ComReferenceNode Overload

Microsoft.VisualStudio.Package Namespace