RevokeDragDrop

Revokes the registration of the specified application window as a potential target for OLE drag-and-drop operations.

WINOLEAPI RevokeDragDrop(
  HWND hwnd  //Handle to a window that can accept drops
);
 

Parameter

hwnd
[in] Handle to a window previously registered as a target for an OLE drag-and-drop operation.

Return Values

This function supports the standard return value E_OUTOFMEMORY, as well as the following:

S_OK
Registration as a target window was revoked successfully.
DRAGDROP_E_INVALIDHWND
Invalid handle returned in the hwnd parameter.
DRAGDROP_E_NOTREGISTERED
An attempt was made to revoke a drop target that has not been registered.

Remarks

When your application window is no longer available as a potential target for an OLE drag-and-drop operation, you must call RevokeDragDrop.

This function calls the IUnknown::Release method for your drop target interface.

QuickInfo

  Windows NT: Use version 3.1 or later.
  Windows: Use Windows 95 or later.
  Windows CE: Unsupported.
  Header: Declared in ole2.h.
  Import Library: Included as a resource in ole32.dll.

See Also

RegisterDragDrop