DataObject::GetFormats Method (Boolean)

Returns a list of formats in which the data in this data object is stored. A Boolean flag indicates whether to also include formats that the data can be automatically converted to.

Namespace:  System.Windows
Assembly:  PresentationCore (in PresentationCore.dll)

public:
virtual array<String^>^ GetFormats(
	bool autoConvert
) sealed

Parameters

autoConvert
Type: System::Boolean

true to retrieve all formats in which the data in this data object is stored, or can be converted to; false to retrieve only formats in which the data in this data object is stored.

Return Value

Type: array<System::String>
An array of strings, with each string specifying the name of a format supported by this data object.

Implements

IDataObject::GetFormats(Boolean)

For a set of predefined data formats, see the DataFormats class.

The following example uses this method to get an array of strings denoting only data formats available in a data object (auto-convertible data formats are filtered).

No code example is currently available or this language may not be supported.

.NET Framework

Supported in: 4.6, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2015 Microsoft