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. Image for the cookie policy date
close icon

Enhanced Row Selection

Hi, I have the need for a special selection implementation in my 4.1.0.50 GridControl. I have attached an image of part of my GUI to help show my layout. I have set it up kind of like Windows Explorer first of all. To help explain the image, each icon is in its own column (with their respective hearders being in a CoveredRange), and this makes a total of 12 columns. The following is what I''m looking for... -If the user selects a label in column 3 or 4 (Name of Device), each of the 2 columns are highlighted for that row. -If the user selects/highlights a checkbox cell, then each of the checkbox cells in that row are highlighted, except the cell which is the "CurrentCell" -Also, I''d like a form of extended multi-selection to be possible. I have tried a number of things with the PrepareViewStyleInfo and CellDrawn events, as well as played around alot with the AllowSelection and ListBoxSelectionMode options, but with no success. Can you give me a suggestion how to tackle this? Thank you very much ahead of time...

varselect_screenshot.zip

3 Replies

AD Administrator Syncfusion Team June 8, 2006 05:56 AM UTC

Hi Mitch, The intent behavior can be achieved by handling the PrepareViewStyleInfo and few other events. Please have a look at the attached sample and let us know if this serves your need. Regards, Calvin.

Selections.zip


MT Mitch Todd June 8, 2006 10:39 AM UTC

Hey Calvin, Thanks alot for the sample. I think I''ve implemented nearly the solution that I need. One other thing however... I actually created a custom cell type, as you might have been able to tell from my screenshot, that provides a much bigger checkbox. The problem is, however, that it is not possible to see when this row is highlighted, because the BackColor is literally behind the checkbox (I use an image for the checkbox)...The selection is easily visible when the grid has a ListBoxSelectionMode, as the alphablend seems to be on the top. Is there a way I can achieve this in the PrepareViewStyleInfo event? Thanks,


AD Administrator Syncfusion Team June 8, 2006 12:38 PM UTC

Hi Mitch, The intent behavior can be achieved by handling the CellDrawn event. Modified sample attached. Regards, Calvin.

Selections0.zip

Loader.
Live Chat Icon For mobile
Up arrow icon