DataFormats DataFormats DataFormats DataFormats Class

Definition

Provides a set of predefined data format names that can be used to identify data formats available in the clipboard or drag-and-drop operations.

public ref class DataFormats abstract sealed
public static class DataFormats
type DataFormats = class
Public Class DataFormats
Inheritance
DataFormatsDataFormatsDataFormatsDataFormats

Remarks

The DataObject class and other classes that implement the IDataObject interface use the static formats defined by DataFormats to describe each data format that is stored in a data object. Data objects are typically used for transferring data to and from the system clipboard, and in drag-and-drop operations.

The following table lists the values of the static data format fields provided by DataFormats. These field values are provided for informational purposes only; in general, code should always refer to the appropriate field, rather than hard-coded strings.

Field Field Value Description
Bitmap "Bitmap" Specifies a Microsoft Windows bitmap data format.
CommaSeparatedValue "CSV" Specifies a comma-separated value (CSV) data format.
Dib "DeviceIndependentBitmap" Specifies the device-independent bitmap (DIB) data format.
Dif "DataInterchangeFormat" Specifies the Windows Data Interchange Format (DIF) data format.
EnhancedMetafile "EnhancedMetafile" Specifies the Windows enhanced metafile format.
FileDrop "FileDrop" Specifies the Windows file drop format.
Html "HTML Format" Specifies the HTML data format.
Locale "Locale" Specifies the Windows locale (culture) data format.
MetafilePicture "MetaFilePict" Specifies the Windows metafile picture data format.
OemText "OEMText" Specifies the standard Windows OEM text data format.
Palette "Palette" Specifies the Windows palette data format.
PenData "PenData" Specifies the Windows pen data format.
Riff "RiffAudio" Specifies the Resource Interchange File Format (RIFF) audio data format.
Rtf "Rich Text Format" Specifies the Rich Text Format (RTF) data format.
Serializable "PersistentObject" Specifies a data format that encapsulates any type of serializable data objects.
StringFormat "System.String" Specifies the common language runtime (CLR) string class data format.
SymbolicLink "SymbolicLink" Specifies the Windows symbolic link data format.
Text "Text" Specifies the ANSI text data format.
Tiff "TaggedImageFileFormat" Specifies the Tagged Image File Format (TIFF) data format.
UnicodeText "UnicodeText" Specifies the Unicode text data format.
WaveAudio "WaveAudio" Specifies the wave audio data format.
Xaml "Xaml" Specifies the Extensible Application Markup Language (XAML) data format.
XamlPackage "XamlPackage" Specifies the Extensible Application Markup Language (XAML) package data format.

Fields

Bitmap Bitmap Bitmap Bitmap

Specifies a Microsoft Windows bitmap data format.

CommaSeparatedValue CommaSeparatedValue CommaSeparatedValue CommaSeparatedValue

Specifies a comma-separated value (CSV) data format.

Dib Dib Dib Dib

Specifies the DIB data format.

Dif Dif Dif Dif

Specifies the Windows Data Interchange Format (DIF) data format.

EnhancedMetafile EnhancedMetafile EnhancedMetafile EnhancedMetafile

Specifies the Windows enhanced metafile format.

FileDrop FileDrop FileDrop FileDrop

Specifies the Windows file drop format.

Html Html Html Html

Specifies the HTML data format.

Locale Locale Locale Locale

Specifies the Windows locale (culture) data format.

MetafilePicture MetafilePicture MetafilePicture MetafilePicture

Specifies the Windows metafile picture data format.

OemText OemText OemText OemText

Specifies the standard Windows OEM text data format.

Palette Palette Palette Palette

Specifies the Windows palette data format.

PenData PenData PenData PenData

Specifies the Windows pen data format.

Riff Riff Riff Riff

Specifies the Resource Interchange File Format (RIFF) audio data format.

Rtf Rtf Rtf Rtf

Specifies the Rich Text Format (RTF) data format.

Serializable Serializable Serializable Serializable

Specifies a data format that encapsulates any type of serializable data objects.

StringFormat StringFormat StringFormat StringFormat

Specifies the common language runtime (CLR) string class data format.

SymbolicLink SymbolicLink SymbolicLink SymbolicLink

Specifies the Windows symbolic link data format.

Text Text Text Text

Specifies the ANSI text data format.

Tiff Tiff Tiff Tiff

Specifies the Tagged Image File Format (TIFF) data format.

UnicodeText UnicodeText UnicodeText UnicodeText

Specifies the Unicode text data format.

WaveAudio WaveAudio WaveAudio WaveAudio

Specifies the wave audio data format.

Xaml Xaml Xaml Xaml

Specifies the Extensible Application Markup Language (XAML) data format.

XamlPackage XamlPackage XamlPackage XamlPackage

Specifies the Extensible Application Markup Language (XAML) package data format.

Methods

GetDataFormat(Int32) GetDataFormat(Int32) GetDataFormat(Int32) GetDataFormat(Int32)

Returns a DataFormat object that defines a name and numeric ID for the specified data format. The desired data format is specified by numeric ID.

GetDataFormat(String) GetDataFormat(String) GetDataFormat(String) GetDataFormat(String)

Returns a DataFormat object that defines a name and numeric ID for the specified data format. The desired data format is specified by name (a string).

Applies to