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. Image for the cookie policy date

How can I sort the grid EXCEPT FOR the last row?

Hi, I am using DataBoundGrid. I want to sort the data by clicking the header, but I do not want the last row will always stay on the bottom. Is there any good way to do that? Thanks a lot Chris

1 Reply

AD Administrator Syncfusion Team April 29, 2004 03:51 PM UTC

I do not know of any way to use the default DataView sorting in the GridDataBooundGrid and get this done. One way to do this is to do your own sorting. You can create an indexer arraylist that is used to index the look up of items in your data source. Forcing the grid to use the indexer lookup can be done by handling a couple of events that are part of the grid''s virtual data support. Once this is done, you can do your own sorting by creating an IComparer object that sorts things in the way you want. Here is a sample that does not sort the last row. CustomSortInGDBG_6728.zip

Live Chat Icon For mobile
Up arrow icon