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.

GGC automatically populates TableDescriptor.Columns

Thread ID:

Created:

Updated:

Platform:

Replies:

94472 May 14,2010 12:54 PM May 18,2010 08:50 AM Windows Forms 1
loading
Tags: GridControl
Myles Kelman
Asked On May 14, 2010 12:54 PM

When the .DataSource/.DataMember properties are set on the GridGroupingControl the TableDescriptor.Columns collection is automatically populated, based on the bound DataTable, if the .Columns collection is empty. How can I prevent this behavior?

Arulraj A [Syncfusion]
Replied On May 18, 2010 08:50 AM

Hi Myles,

Thanks for your interest in Syncfusion Products.

To avoid auto population of collections you need to modify the tableDescriptor’s column. Using the following code, this can be achieved.


//To avoid auto population of collections
this.gridGroupingControl1.TableDescriptor.Columns.Modify(); //Or use this code: this.gridGroupingControl1.TableDescriptor.Columns.Clear();
//Use these codes to reset the autopopulate, After this only the datasource will be loaded again at any time.
//this.gridGroupingControl1.TableDescriptor.Columns.Reset();//Or use this code: this.gridGroupingControl1.ResetTableDescriptor();


Here is a sample for your reference.
http://www.syncfusion.com/uploads/redirect.aspx?&team=support&file=GGCTableDescriptor-1103592224.zip

Regards,
Arulraj.A

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.

;