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.

GridGroupingControl - Prevent few columns from sorting.

Thread ID:

Created:

Updated:

Platform:

Replies:

37558 Nov 24,2005 10:51 AM Nov 24,2005 12:24 PM Windows Forms 1
loading
Tags: GridControl
Badri Rajani Kanth
Asked On November 24, 2005 10:51 AM

Hi, I want to prevent few columns from sorting. I mean user should not be able to click them ideally. Or if he clicks, we should not display sort icon and not do sorting. I am trying with e.Cancel = true in SortedColumns_Changed event. But no use. Earlier I worked with event. SO, i am trying again. Any property/alternative event available? Rgds Rajani Kanth

Administrator [Syncfusion]
Replied On November 24, 2005 12:24 PM

You can use the TableControlQueryAllowSortcolumn event.
private void gridGroupingControl1_TableControlQueryAllowSortColumn(object sender, GridQueryAllowSortColumnEventArgs e)
{
	if(e.Column.Name == "ParentDec")
		e.AllowSort = false;
}

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.

;