clearData method
Removes one or more data formats from the clipboard through the dataTransfer object. For the clipboardData object, this method clears all formats.
Syntax
retVal = object.clearData(format);
Parameters
format [in, optional]
Type: BSTR
A BSTR that specifies one or more of the following data format values to clear from a dataTransfer object.
Text
Removes the text format.
URL
Removes the URL format.
File
Removes the file format.
HTML
Removes the HTML format.
Image
Removes the image format.
Standards information
There are no standards that apply here.
Remarks
If no format parameter is passed, the data formats are cleared.
For drag-and-drop operations, the IHTMLDataTransfer::clearData method of the dataTransfer object is used generally in source events, such as HTMLFrameSiteEvents::ondragstart. When you override the default behavior of the target, use IHTMLDataTransfer::clearData in the HTMLFrameSiteEvents::ondrop event. It is particularly useful for selectively removing data formats when multiple formats are specified.
See also
Reference
Conceptual