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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

what''s the difference between TableDescriptor.Columns.Remove and TableDescriptor.VisibleColumns.Remove

Thread ID:





64336 Jul 18,2007 03:36 PM UTC Jul 20,2007 03:33 PM UTC WinForms 3
Tags: Grouping
Feng Wen
Asked On July 18, 2007 03:36 PM UTC


I thought I may not able to sort by the column after I remove it but I still can, thus I can not find any difference between them.


Rajagopal [Syncfusion]
Replied On July 18, 2007 08:16 PM UTC

Hi Frank,

The TableDescriptor.Columns is a collection of columns to the columns of the underlying datasource. The TableDescriptor.VisibleColumns is a collection of GridVisibleColumnsDescriptor columns each referencing a column in the TableDescriptor.Columns collection. This columns defines the order of columns shown in the grid.

Calling the VisibleColumns.Remove() will just hide the column from being shown in grid. If you want to avoid sorting for certain columns then you could do this by handling the TableControlQueryAllowSortColumn.

void gridGroupingControl1_TableControlQueryAllowSortColumn(object sender, GridQueryAllowSortColumnEventArgs e)
if(e.Column.Name == "columnName")
e.AllowSort = false;

Let me know if this helps.


Feng Wen
Replied On July 18, 2007 08:40 PM UTC

My problem is, if I call TableDescriptor.Columns.Remove() after groupingGrid.TableDescriptor.VisibleColumns.Remove("ColumnName");

The column will gone and leave a blank gap in the grid(see pic), but if I call Columns.Remove() without VisibleColumns.Remove(). The columns in the grid will arrange automatically so there is no such gap.


haneefm [Syncfusion]
Replied On July 20, 2007 03:33 PM UTC

Hi Frank,

I am not sure of what be might be causing this strange behavior without a working sample. I have tested this issue in browser sample with Essentail studio V.4.x/5.x. But i was not able to reproduce the issue. Is it possible for you to upload us a minimal sample or modify the browser sample to reproduce the issue here? This will help us to analyse the issue further.

Best regards,


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.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon 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.Close Icon