Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

DataObject Methods

The DataObject type exposes the following members.

  Name Description
Public method ContainsAudio Indicates whether the data object contains data in the WaveAudio format.
Public method ContainsFileDropList Indicates whether the data object contains data that is in the FileDrop format or can be converted to that format.
Public method ContainsImage Indicates whether the data object contains data that is in the Bitmap format or can be converted to that format.
Public method ContainsText() Indicates whether the data object contains data in the UnicodeText format.
Public method ContainsText(TextDataFormat) Indicates whether the data object contains text data in the format indicated by the specified TextDataFormat value.
Public method Equals(Object) Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected method Finalize Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public method GetAudioStream Retrieves an audio stream from the data object.
Public method GetData(String) Returns the data associated with the specified data format.
Public method GetData(Type) Returns the data associated with the specified class type format.
Public method GetData(String, Boolean) Returns the data associated with the specified data format, using an automated conversion parameter to determine whether to convert the data to the format.
Public method GetDataPresent(String) Determines whether data stored in this DataObject is associated with, or can be converted to, the specified format.
Public method GetDataPresent(Type) Determines whether data stored in this DataObject is associated with, or can be converted to, the specified format.
Public method GetDataPresent(String, Boolean) Determines whether this DataObject contains data in the specified format or, optionally, contains data that can be converted to the specified format.
Public method GetFileDropList Retrieves a collection of file names from the data object.
Public method GetFormats() Returns a list of all formats that data stored in this DataObject is associated with or can be converted to.
Public method GetFormats(Boolean) Returns a list of all formats that data stored in this DataObject is associated with or can be converted to, using an automatic conversion parameter to determine whether to retrieve only native data formats or all formats that the data can be converted to.
Public method GetHashCode Serves as the default hash function. (Inherited from Object.)
Public method GetImage Retrieves an image from the data object.
Public method GetText() Retrieves text data from the data object in the UnicodeText format.
Public method GetText(TextDataFormat) Retrieves text data from the data object in the format indicated by the specified TextDataFormat value.
Public method GetType Gets the Type of the current instance. (Inherited from Object.)
Protected method MemberwiseClone Creates a shallow copy of the current Object. (Inherited from Object.)
Public method SetAudio(Byte[]) Adds a Byte array to the data object in the WaveAudio format after converting it to a Stream.
Public method SetAudio(Stream) Adds a Stream to the data object in the WaveAudio format.
Public method SetData(Object) Adds the specified object to the DataObject using the object type as the data format.
Public method SetData(String, Object) Adds the specified object to the DataObject using the specified format.
Public method SetData(Type, Object) Adds the specified object to the DataObject using the specified type as the format.
Public method SetData(String, Boolean, Object) Adds the specified object to the DataObject using the specified format and indicating whether the data can be converted to another format.
Public method SetFileDropList Adds a collection of file names to the data object in the FileDrop format.
Public method SetImage Adds an Image to the data object in the Bitmap format.
Public method SetText(String) Adds text data to the data object in the UnicodeText format.
Public method SetText(String, TextDataFormat) Adds text data to the data object in the format indicated by the specified TextDataFormat value.
Public method ToString Returns a string that represents the current object. (Inherited from Object.)
Top
  Name Description
Explicit interface implemetation Private method IDataObject.DAdvise Infrastructure. Creates a connection between a data object and an advisory sink. This method is called by an object that supports an advisory sink and enables the advisory sink to be notified of changes in the object's data.
Explicit interface implemetation Private method IDataObject.DUnadvise Infrastructure. Destroys a notification connection that had been previously established.
Explicit interface implemetation Private method IDataObject.EnumDAdvise Infrastructure. Creates an object that can be used to enumerate the current advisory connections.
Explicit interface implemetation Private method IDataObject.EnumFormatEtc Infrastructure. Creates an object for enumerating the FORMATETC structures for a data object. These structures are used in calls to GetData or SetData.
Explicit interface implemetation Private method IDataObject.GetCanonicalFormatEtc Infrastructure. Provides a standard FORMATETC structure that is logically equivalent to a more complex structure. Use this method to determine whether two different FORMATETC structures would return the same data, removing the need for duplicate rendering.
Explicit interface implemetation Private method IDataObject.GetData Infrastructure. Obtains data from a source data object. The GetData method, which is called by a data consumer, renders the data described in the specified FORMATETC structure and transfers it through the specified STGMEDIUM structure. The caller then assumes responsibility for releasing the STGMEDIUM structure.
Explicit interface implemetation Private method IDataObject.GetDataHere Infrastructure. Obtains data from a source data object. This method, which is called by a data consumer, differs from the GetData method in that the caller must allocate and free the specified storage medium.
Explicit interface implemetation Private method IDataObject.QueryGetData Infrastructure. Determines whether the data object is capable of rendering the data described in the FORMATETC structure. Objects attempting a paste or drop operation can call this method before calling GetData to get an indication of whether the operation may be successful.
Explicit interface implemetation Private method IDataObject.SetData Infrastructure. Transfers data to the object that implements this method. This method is called by an object that contains a data source.
Top
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.