Condividi tramite


IVsToolbox.AddItem Method

Adds a data object to the specified tab in the Toolbox.

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

Syntax

'Dichiarazione
Function AddItem ( _
    pDO As IDataObject, _
    ptif As TBXITEMINFO(), _
    lpszTab As String _
) As Integer
'Utilizzo
Dim instance As IVsToolbox
Dim pDO As IDataObject
Dim ptif As TBXITEMINFO()
Dim lpszTab As String
Dim returnValue As Integer

returnValue = instance.AddItem(pDO, ptif, _
    lpszTab)
int AddItem(
    IDataObject pDO,
    TBXITEMINFO[] ptif,
    string lpszTab
)
int AddItem(
    [InAttribute] IDataObject^ pDO, 
    [InAttribute] array<TBXITEMINFO>^ ptif, 
    [InAttribute] String^ lpszTab
)
function AddItem(
    pDO : IDataObject, 
    ptif : TBXITEMINFO[], 
    lpszTab : String
) : int

Parameters

  • lpszTab
    Type: System.String

    [in] The localized name of the Toolbox tab to add the data object to. The localized name can be obtained from the invariant non-localized name by calling GetIDOfTab

Return Value

Type: System.Int32

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Remarks

COM Signature

From vsshell.idl:

HRESULT IVsToolbox::AddItem(
   [in]IDataObject* pDO,
   [in]PTBXITEMINFO ptif,
   [in]LPCOLESTR lpszTab
);

Permissions

See Also

Reference

IVsToolbox Interface

IVsToolbox Members

Microsoft.VisualStudio.Shell.Interop Namespace