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.

Sorting for IList bound grids

Thread ID:

Created:

Updated:

Platform:

Replies:

3100 Mar 3,2003 01:04 AM Jul 3,2003 05:05 PM Windows Forms 3
loading
Tags: GridControl
Apolon Ivankovic
Asked On March 3, 2003 01:04 AM

The grid sorting functionality isn't active in the forms I've created. All of them use IList based data binding and in particular a partial implementation of the IBindingList interface. Could someone confirm whether Essential grid will only supply the column sorting user interface functionality if an IBindingList implementation in the DataSource performs the sorting? Or is there some setting I'm missing to activate the user interface sorting functionality?

Administrator [Syncfusion]
Replied On March 3, 2003 06:32 AM

If you are using a GridDataBoundGrid and want sorting, then you will have to implement IBindingList.ApplySort and IBindingList.SupportsSorting.

Administrator [Syncfusion]
Replied On July 3, 2003 02:06 PM

> If you are using a GridDataBoundGrid and want sorting, then you will have to implement IBindingList.ApplySort and IBindingList.SupportsSorting. > Does anything need to change in the Form that contains the grid? Do I add the sorting algorithm to ApplySort and that is it? Thanks,

Administrator [Syncfusion]
Replied On July 3, 2003 05:05 PM

As far as I know, you should just implement your sorting in ApplySort based on the PropertyDescriptor and ListSortDirection passed in. You would also want to implement the other sorting implementation methods like SupportsSorting, IsSorted, SortDirection, RemoveSort, etc. You would also need to fire listchanged events as required by the IBindingList docs (eg. ms-help://MS.VSCC/MS.MSDNVS/cpref/html/frlrfsystemcomponentmodelibindinglistclassapplysorttopic.htm) On the form, you should make sure the grid.SortBehavior property is set, but that would be all. Did you try this, and it not 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.

;