Back to Devexpress

TileViewColumns.BackgroundImageColumn Property

windowsforms-devexpress-dot-xtragrid-dot-columns-dot-tileviewcolumns-7a0f9953.md

latest4.2 KB
Original Source

TileViewColumns.BackgroundImageColumn Property

Gets or sets the column that contains images to display in tiles’ background.

Namespace : DevExpress.XtraGrid.Columns

Assembly : DevExpress.XtraGrid.v25.2.dll

NuGet Packages : DevExpress.Win.Grid, DevExpress.Win.Navigation

Declaration

csharp
[DefaultValue(null)]
public GridColumn BackgroundImageColumn { get; set; }
vb
<DefaultValue(Nothing)>
Public Property BackgroundImageColumn As GridColumn

Property Value

TypeDefaultDescription
GridColumnnull

A GridColumn object representing the column that contains images to display in tiles’ background.

|

Remarks

If you want to set images from a specific grid column as tile background images, you can either create an element that corresponds to this column and set appropriate values for this element’s TileItemElement.ImageScaleMode and TileItemElement.ImageAlignment properties, or assign this column to the BackgroundImageColumn property. The advantage of the second approach is that images set as tile background images can stretch over the entire tile, ignoring its padding. To do the same with elements, explicitly set tile paddings to 0, 0, 0, 0.

To arrange background images or modify their scale mode, use the TileViewItemOptions.ItemBackgroundImageAlignment or TileViewItemOptions.ItemBackgroundImageScaleMode properties respectively.

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the BackgroundImageColumn property.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

winforms-grid-tileview-thumbnails-async-load/CS/TileView-ManualThumbs/Form1.cs#L28

csharp
// Specify a column that provides information on images to render.
tileView1.ColumnSet.BackgroundImageColumn = colName;
tileView1.OptionsImageLoad.RandomShow = true;

winforms-grid-tileview-thumbnails-async-load/VB/TileView-ManualThumbs/Form1.vb#L25

vb
' Specify a column that provides information on images to render.
tileView1.ColumnSet.BackgroundImageColumn = colName
tileView1.OptionsImageLoad.RandomShow = True

See Also

Tile View

CheckedColumn

GroupColumn

EnabledColumn

TileViewColumns Class

TileViewColumns Members

DevExpress.XtraGrid.Columns Namespace