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

GridGrouping - How to hide the column?

Thread ID:





49197 Sep 13,2006 07:30 AM UTC Feb 11,2016 12:05 PM UTC WinForms 3
Tags: GridControl
Administrator [Syncfusion]
Asked On September 13, 2006 07:30 AM UTC


how to hide a specific column of the grid?
I want to get the value of the hidden column when user click on any cell of the row.

My grid is allowed to Group.


Administrator [Syncfusion]
Replied On September 13, 2006 09:08 AM UTC

Hi Lim,

Use the VisibleColumns property of the GridTableDescriptor to show / hide / move the columns in the grid. Below is a code snippet

//For hide the "Col0" column

//For show the "Col0" column

//For move columns in a grid.

To get the value of the hidden column, you need to call the Record.GetValue method in TablecontrolCellClick event.

GridRecordRow recRow = e.TableControl.Table.DisplayElements[e.Inner.RowIndex] as GridRecordRow;
if(recRow != null)
Console.WriteLine(recRow.ParentRecord.GetValue("Col0") );


QLT User
Replied On February 10, 2016 02:55 PM UTC

how do i move the column if i dont know its current position ? is there a way to get its current position and then use variables in the move method ?

Pavithra Kodiyarasan [Syncfusion]
Replied On February 11, 2016 12:05 PM UTC

Dear Customer,

Thank you for contacting Syncfusion Support.

You can get current position of the column by using IndexOf() method and move the column by Move() method. Please find the Code example and sample below.

Code Example:

int columnindex = this.gridGroupingControl1.TableDescriptor.Columns.IndexOf("Name"); //get the Column index of column "Name"

this.gridGroupingControl1.TableDescriptor.Columns.Move(columnindex, 0); //Move the column to zero index.




Pavithra K.


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