System.Windows.Forms.DataObject.GetImage Method

Retrieves an image from the data object.

Syntax

public virtual System.Drawing.Image GetImage ()

Returns

An System.Drawing.Image representing the image data in the data object or null if the data object does not contain any data that is in the DataFormats.Bitmap format or can be converted to that format.

Remarks

Use the DataObject.ContainsImage method to determine whether the data object contains image data before retrieving it with this method.

Use the DataObject.SetImage(System.Drawing.Image) method to add image data to the data object.

Requirements

Namespace: System.Windows.Forms
Assembly: System.Windows.Forms (in System.Windows.Forms.dll)
Assembly Versions: 2.0.0.0