A newer version of this page is available. Switch to the current version.

BaseImageListBoxControl.GetItemImage(Int32) Method

Gets the image displayed within the specified item.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.XtraEditors.v19.2.dll


public virtual Image GetItemImage(
    int index


Name Type Description
index Int32

An integer value representing the zero-based index of the item.


Type Description

A Image object value specifying the image displayed within the specified item. -1 if no item is found.


Each ImageListBoxItem can display an image contained within the object represented by the BaseImageListBoxControl.ImageList property. The GetItemImage method allows you to get the image displayed in the specified item. This method can be especially useful when the data source is bound to the control. Note that the method returns -1 if the BaseImageListBoxControl.ImageMember property value is set to String.Empty.

When no data source is bound, you can obtain the image of the specified item using the ImageListBoxItem.Image property.

See Also