FlexGrid for WinForms
Undoing a Sort
Show AllShow All
Hide AllHide All

To undo a sort in C1FlexGrid when the grid is bound to a DataTable, set the DefaultView property to null.

Add the following code to the Button1_Click event:

To write code in Visual Basic

To write code in C#

Note: The DataTable.DefaultView returns the DataView of the DataTable, and setting the sort string to null forces the DataView to undo the previous sort.

This topic illustrates the following:

Click the Last Name column to sort on it.


Click the Undo button, and the sort will be undone.


See Also

 

 


Copyright © GrapeCity, inc. All rights reserved.

Product Support Forum |  Documentation Feedback