Export (0) Print
Expand All

IFileOperation::DeleteItems method

Declares a set of items that are to be deleted.

Syntax


HRESULT DeleteItems(
  [in]  IUnknown *punkItems
);

Parameters

punkItems [in]

Type: IUnknown*

Pointer to the IUnknown of the IShellItemArray, IDataObject, or IEnumShellItems object which represents the group of items to be deleted. You can also point to an IPersistIDList object to represent a single item, effectively accomplishing the same function as IFileOperation::DeleteItem.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

This method does not delete the items, it merely declares the items to be deleted. To delete a group of items, you must make at least the sequence of calls detailed here:

  1. Call IFileOperation::DeleteItems to declare the files or folders to be deleted.
  2. Call IFileOperation::PerformOperations to begin the delete operation.

Requirements

Minimum supported client

Windows Vista [desktop apps only]

Minimum supported server

Windows Server 2008 [desktop apps only]

Header

Shobjidl.h

IDL

Shobjidl.idl

See also

IFileOperation
IFileOperation::DeleteItem

 

 

Community Additions

ADD
Show:
© 2014 Microsoft