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

GridList Control and Columns

I am currently bining a strongly-typed collection of objects to a GridList control (v3.3). The problem is all of the properties are showing up as columns and I want to programatically decide which properties to display. Does anyone have some example code? Is this possible without hiding columns? Thanks.

1 Reply

AD Administrator Syncfusion Team November 17, 2005 11:00 PM UTC

The simplest way is to hide the columns: gridListControl1.Grid.Cols.Hidden[2] = true; //hide column 2.... If you want a solution that yo9u can implement on your collections, you can have the IList object implement ITypedList. (This will also alos you to control the display order of the properties.) Here is a forum thread that has sample code. http://www.syncfusion.com/Support/Forums/message.aspx?MessageID=9194 In the GetItemsProperties, get the default property order using the techinque shown in this forum thread. But before returning the collection, reorder the colection to the order you prefer or remove any properties you do not want to use.

Loader.
Live Chat Icon For mobile
Up arrow icon