IVsObjectList::GetMultipleSourceItems Method (UInt32, UInt32, UInt32, array<VSITEMSELECTION>^)

 

Returns the ItemID corresponding to source files for the given list item if more than one.

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

int GetMultipleSourceItems(
	unsigned int index,
	unsigned int grfGSI,
	unsigned int cItems,
	array<VSITEMSELECTION>^ rgItemSel
)

Parameters

index
Type: System::UInt32

[in] Specifies the index of the list item of interest.

grfGSI
Type: System::UInt32

[in] Flag providing information about how the selected items should be returned. Values are taken from the __VSGSIFLAGS enumeration.

cItems
Type: System::UInt32

[in] The number of items returned in rgItemSel.

rgItemSel
Type: array<Microsoft.VisualStudio.Shell.Interop::VSITEMSELECTION>^

[out] Array of VSITEMSELECTION structures that contain an IVsHierarchy pointer and item identifier for each selected item.

Return Value

Type: System::Int32

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

From vsshell.idl:

HRESULT IVsObjectList::GetMultipleSourceItems(
   [in] ULONG Index,
   [in] VSGSIFLAGS grfGSI,
   [in] ULONG cItems,
   [out, size_is(cItems)] VSITEMSELECTION rgItemSel[]
);

The environment calls GetMultipleSourceItems if an initial call to CountSourceItems returns a count greater than 1. All ItemIds must belong to the same IVsHierarchy (returned through CountSourceItems.

This method applies to Class View only.

Return to top
Show: