I have a grid that I default to be sorted by a date/time column. If I edit the datatable and change a value in that column the grid does not maintain it's sorting. If I add a row to the datatable, it will always be shown at the bottom of the list and not in it's properly sorted location. How can maintain the sorted order of the grid after changes?
Hi,
The grid doesn't automatically refresh the sorting when rows are added or changed. This is to prevent a case where the user types into a cell and the row suddenly moves to a new position in the grid, which could be rather confusing.
If you want to refresh the sorting, you can call the RefreshSortPosition on the grid row (to sort a single row into it's proper place) or call Refresh on the SortedColumns collection of the band to re-sort everything.