Retrieves the collection of elements that are being dragged as part of a drag operation.
HRESULT GetGrabbedItems( SAFEARRAY **pRetVal );
An array of VT_UNKNOWN pointers to the IRawElementProviderSimple interfaces of the elements that are being dragged. This parameter is NULL if only a single item is being dragged.
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
If the user is dragging multiple items, the items are represented by a single master element with an associated set of grabbed elements. The master element raises the appropriate events, to avoid having a large set of duplicate events. The client can call GetGrabbedItems to retrieve the full list of grabbed items. The provider should allocate a SAFEARRAY of appropriate length and add the Component Object Model (COM) pointers of the elements that are part of the drag operation.
|Minimum supported client||Windows 8 [desktop apps | UWP apps]|
|Minimum supported server||Windows Server 2012 [desktop apps | UWP apps]|
|Header||uiautomationcore.h (include UIAutomation.h)|