We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Image List Display in Grid Cell

Thread ID:

Created:

Updated:

Platform:

Replies:

71847 Feb 15,2008 10:18 AM Feb 15,2008 10:43 AM Windows Forms 1
loading
Tags: GridControl
Landon
Asked On February 15, 2008 10:18 AM

I am attempting to use an ImageList to display either a check mark or a blank image based on the data value of that column being 1 or 0. So far, with the gridGroupingControl, this is working out great, except that there are these weird blue dots in the cells. Can someone please tell me what these are? They are making the images look weird. When I set this image to the background property of the cell, it looks perfect, so I know it is not the image. Perhaps there is a property of the ImageList or the cell style I am over looking? Your help would be greatly appreciated. Below is a small sample of my code. Thanks for your help!

ImageList images = new ImageList();
images.Images.Add(HillRom.Utility.UI.ImageManager.GetEmbeddedBitmap("no_check.png"));
images.Images.Add(HillRom.Utility.UI.ImageManager.GetEmbeddedBitmap("green_check.png"));

Syncfusion.Windows.Forms.Grid.GridStyleInfo style = gridGroupingControl.TableDescriptor.Columns["Priority"].Appearance.AnyRecordFieldCell;
style.CellType = "Image";
style.ImageList = images;
style.ImageSizeMode = Syncfusion.Windows.Forms.Grid.GridImageSizeMode.Normal;



example.zip

Landon
Replied On February 15, 2008 10:43 AM

Nevermind, the problem was with the image itself and / or the color depth of the image list. I re-created the PNG images with zero compress, and set the imageList color depth to 32 bit and this corrected the problem. Maybe this will help someone else. Thanks.

>I am attempting to use an ImageList to display either a check mark or a blank image based on the data value of that column being 1 or 0. So far, with the gridGroupingControl, this is working out great, except that there are these weird blue dots in the cells. Can someone please tell me what these are? They are making the images look weird. When I set this image to the background property of the cell, it looks perfect, so I know it is not the image. Perhaps there is a property of the ImageList or the cell style I am over looking? Your help would be greatly appreciated. Below is a small sample of my code. Thanks for your help!

ImageList images = new ImageList();
images.Images.Add(HillRom.Utility.UI.ImageManager.GetEmbeddedBitmap("no_check.png"));
images.Images.Add(HillRom.Utility.UI.ImageManager.GetEmbeddedBitmap("green_check.png"));

Syncfusion.Windows.Forms.Grid.GridStyleInfo style = gridGroupingControl.TableDescriptor.Columns["Priority"].Appearance.AnyRecordFieldCell;
style.CellType = "Image";
style.ImageList = images;
style.ImageSizeMode = Syncfusion.Windows.Forms.Grid.GridImageSizeMode.Normal;



example.zip


CONFIRMATION

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.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;