EnumClipboardFormats

  UINT EnumClipboardFormats(uFormat)    
  UINT uFormat; /* known clipboard format */

This function enumerates the formats found in a list of available formats that belong to the clipboard. On each call to this function, the uFormat parameter specifies a known available format, and the function returns the format that appears next in the list. The first format in the list can be retrieved by setting uFormat to zero.

Parameters

uFormat

Specifies a known format.

Return Value

The return value specifies the next known clipboard data format. It is zero if uFormat specifies the last format in the list of available formats. It is zero if the clipboard is not open.

Comments

Before it enumerates the formats by using the EnumClipboardFormats function, an application must open the clipboard by using the OpenClipboard function.

The order that an application uses for putting alternative formats for the same data into the clipboard is the same order that the enumerator uses when returning them to the pasting application. The pasting application should use the first format enumerated that it can handle. This gives the donor a chance to recommend formats that involve the least loss of data.

See Also

OpenClipboard, CountClipboardFormats, RegisterClipboardFormat