Inserts the specified node and its child nodes, if any, under the specified parent node.
Namespace: Microsoft.VisualStudio.Data.Services.SupportEntities
Assembly: Microsoft.VisualStudio.Data.Services (in Microsoft.VisualStudio.Data.Services.dll)
Syntax
'Declaration
Function InsertItem ( _
parentItemId As Integer, _
childSelectionInfo As IVsDataViewSelectionInfo, _
newItemId As Integer, _
identifier As Object() _
) As Boolean
'Usage
Dim instance As IVsDataViewHierarchy
Dim parentItemId As Integer
Dim childSelectionInfo As IVsDataViewSelectionInfo
Dim newItemId As Integer
Dim identifier As Object()
Dim returnValue As Boolean
returnValue = instance.InsertItem(parentItemId, _
childSelectionInfo, newItemId, identifier)
bool InsertItem(
int parentItemId,
IVsDataViewSelectionInfo childSelectionInfo,
int newItemId,
Object[] identifier
)
bool InsertItem(
int parentItemId,
IVsDataViewSelectionInfo^ childSelectionInfo,
int newItemId,
array<Object^>^ identifier
)
function InsertItem(
parentItemId : int,
childSelectionInfo : IVsDataViewSelectionInfo,
newItemId : int,
identifier : Object[]
) : boolean
Parameters
parentItemId
Type: System.Int32The full name of the new node's parent.
childSelectionInfo
Type: Microsoft.VisualStudio.Data.Services.IVsDataViewSelectionInfoThe selection of child nodes to insert beneath the new node.
newItemId
Type: System.Int32A numerical identifier for the new node to insert.
identifier
Type: array<System.Object[]An array containing identifier parts that represent the new node.
Return Value
Type: System.Boolean
true if the node was inserted; otherwise, false.
Exceptions
| Exception | Condition |
|---|---|
| ArgumentNullException | The childSelectionInfo parameter is nulla null reference (Nothing in Visual Basic). |
| ArgumentException | The childSelectionInfo parameter is not a child of the specified parent node. |
.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.
See Also
Reference
IVsDataViewHierarchy Interface
Microsoft.VisualStudio.Data.Services.SupportEntities Namespace