Skip to main content
A newer version of this page is available. .

ExcelFilteringDataEventArgs.HtmlImages Property

Gets or sets a collection of images to be inserted into filter item captions using HTML tags. This property is in effect when the HTML formatting feature is enabled for filter item captions.

Namespace: DevExpress.XtraEditors.Filtering

Assembly: DevExpress.XtraEditors.v19.1.dll

Declaration

public object HtmlImages { get; set; }

Property Value

Type Description
Object

An image collection (DevExpress.Utils.ImageCollection or DevExpress.Utils.SvgImageCollection).

Remarks

You can format captions of custom filter conditions (see ExcelFilteringDataEventArgs.AddFilter) using a set of simplified HTML tags.

When you compose an HTML string, you can use the image tag to insert an image from an image collection and project’s resources into the text.

To insert an image from an image collection, do the following:

  • Create an image collection (ImageCollection or SvgImageCollection) and populate it with images.
  • Assign the collection to the HtmlImages property.
  • When you use the image tag, address a target image by its name (image names can be obtained from the image collection).

e.HtmlImages = new DevExpress.Utils.ImageCollection();
e.HtmlImages.AddImage(new System.Drawing.Bitmap("D:\\pic.png"), "pic");
if(e.Column == bcModification) {
    e.AddFilter("<image=pic><nbsp>Automatic Transmission (6-speed)", "Contains([" + fieldName + "], '6A')", true);
}
See Also