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.

Reordering columns in a GridDataBoundGrid

Thread ID:

Created:

Updated:

Platform:

Replies:

7323 Sep 19,2003 07:34 AM Sep 19,2003 11:19 AM Windows Forms 1
loading
Tags: GridControl
Doug Lind
Asked On September 19, 2003 07:34 AM

Hi, I'm trying to create a UI to allow clients to control some basic column properties (colors, width, hide, and column order). The grid is a GridDataBoundGrid. At this point, I can handle the colors and header text by creating a GridBoundColumns collection fot the grid. Interstingly, width, and hide appear to be part of the Grid.Model, each as a seperate column indexed collection. My assumption is that reordering columns is simply a matter of the order the are added to the GridBoundColumns. The concern is what does this do to the size mappings in the grid model? How do they get remapped to follow the new column order? I've checked out the example at http://www.syncfusion.com/faq/winforms/search/764.asp but it appears to be specific for GridControls. Am I barking up the wrong tree? It seems that I should just be able to create a new bound columns collection, set the properties for each column and apply the collection. Any suggestions or examples would be greatly appreciated. Thanks, Doug Lind Panther Systems

Administrator [Syncfusion]
Replied On September 19, 2003 11:19 AM

If you use the this.gridDataBoundGrid1.Model.Cols.MoveRange method to move you columns (or allow you user to use the default drag column support), then the column sizes should move appropriately without further work.

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.

;