Thread ID: |
Created: |
Updated: |
Platform: |
Replies: |
24036 | Jan 27,2005 10:12 AM UTC | Jan 27,2005 12:58 PM UTC | WinForms | 7 |
![]() |
Tags: GridControl |
ImageList imageList = new ImageList();
imageList.Images.Add(SystemIcons.Warning.ToBitmap());
imageList.Images.Add(SystemIcons.Application.ToBitmap());
this.gridControl1[3,0].ImageList = imageList;
this.gridControl1[3,0].CellType = "Static";
this.gridControl1[3,0].ImageIndex = 0;
If you want the cell to keep the 3d appearance, also set the style.CellAppearance property.
If you are using a GridDataBoundGrid, then you would need to handle PrepareViewStyleInfo to set the same properties on e.Style based on the values of e.ColIndex and e.RowIndex.
e.Style.CellType = "Image";
e.Style.ImageSizeMode = GridImageSizeMode.CenterImage;
This post will be permanently deleted. Are you sure you want to continue?
Sorry, An error occured while processing your request. Please try again later.
This page will automatically be redirected to the sign-in page in 10 seconds.