Declares a single item that is to be deleted.
HRESULT DeleteItem( [in] IShellItem *psiItem, [in, unique] IFileOperationProgressSink *pfopsItem );
- psiItem [in]
Pointer to an IShellItem that specifies the item to be deleted.
- pfopsItem [in]
Pointer to an IFileOperationProgressSink object to be used for progress status and error notifications for this specific delete operation. If you call IFileOperation::Advise for the overall operation, progress status and error notifications for the delete operation are included there, so set this parameter to NULL.
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
This method does not delete the item, it merely declares the item to be deleted. To delete an item, you must make at least the sequence of calls detailed here:
- Call IFileOperation::DeleteItem to declare the file or folder to be deleted.
- Call IFileOperation::PerformOperations to begin the delete operation.
Minimum supported client
|Windows Vista [desktop apps only]|
Minimum supported server
|Windows Server 2008 [desktop apps only]|
Build date: 11/16/2013