IVsToolWindowToolbarHost2::AddToolbar2 Method (VSTWT_LOCATION, Guid, UInt32, IDropTarget^)

 

Extends the AddToolbar method to allow specifying the drop target to handle drop operations over the toolbar area.

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

int AddToolbar2(
	VSTWT_LOCATION dwLoc,
	[InAttribute] Guid% pGuid,
	unsigned int dwId,
	IDropTarget^ pDropTarget
)

Parameters

dwLoc
Type: Microsoft.VisualStudio.Shell.Interop::VSTWT_LOCATION

[in] Specifies the location of the toolbar within the tool window. Values are taken from the VSTWT_LOCATION enumeration.

pGuid
Type: System::Guid

[in] The GUID of the toolbar's menu group.

dwId
Type: System::UInt32

[in] The ID that, in combination with pguid, identifies the toolbar to be added.

pDropTarget
Type: Microsoft.VisualStudio.OLE.Interop::IDropTarget^

[in] The drop target.

Return Value

Type: System::Int32

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

Return to top
Show: