IVsHierarchyEvents2.OnItemAdded Method

Notifies clients when an item is added to the hierarchy.

Namespace:  Microsoft.VisualStudio.Shell.Interop
Assembly:  Microsoft.VisualStudio.Shell.Interop.11.0 (in Microsoft.VisualStudio.Shell.Interop.11.0.dll)

Syntax

'Declaration
Function OnItemAdded ( _
    itemidParent As UInteger, _
    itemidSiblingPrev As UInteger, _
    itemidAdded As UInteger, _
    ensureVisible As Boolean _
) As Integer
int OnItemAdded(
    uint itemidParent,
    uint itemidSiblingPrev,
    uint itemidAdded,
    bool ensureVisible
)
int OnItemAdded(
    [InAttribute] unsigned int itemidParent, 
    [InAttribute] unsigned int itemidSiblingPrev, 
    [InAttribute] unsigned int itemidAdded, 
    [InAttribute] bool ensureVisible
)
abstract OnItemAdded : 
        itemidParent:uint32 * 
        itemidSiblingPrev:uint32 * 
        itemidAdded:uint32 * 
        ensureVisible:bool -> int
function OnItemAdded(
    itemidParent : uint, 
    itemidSiblingPrev : uint, 
    itemidAdded : uint, 
    ensureVisible : boolean
) : int

Parameters

  • itemidParent
    Type: System.UInt32

    [in] Identifier of the parent, or root node of the hierarchy in which the item is added.

  • itemidSiblingPrev
    Type: System.UInt32

    [in] Identifier that indicates where the item is added in relation to other items (siblings) within the parent hierarchy (itemidParent). If the new item is added at the beginning of the sibling items, then a value of VSITEMID_NIL is specified. If the item is added after a particular node, the Item Id of the node in question is specified.

  • itemidAdded
    Type: System.UInt32

    [in] Identifier of the added item.

  • ensureVisible
    Type: System.Boolean

    Indicates whether to make sure the node is visible after it is added. If true, the node is visible after it is added.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

.NET Framework Security

See Also

Reference

IVsHierarchyEvents2 Interface

Microsoft.VisualStudio.Shell.Interop Namespace