Hi
I have form include GridView that user can change column visibility, size, sort, etc. and then save layout using PersistenceManager.
Because I implement custom paging, in Sorting event, i get sorted data from server.
all process work fine. but when restore layout using PersistenceManager, Column that user already sorted on it restore and data sorted in local mode, not server mode.
Therefore if GridView Sorting event raise automatic or manual after restore layout, my problem will be solved.
Note: I also using below code, but not work:
Could you please help me.
I have form include GridView that user can change column visibility, size, sort, etc. and then save layout using PersistenceManager.
Because I implement custom paging, in Sorting event, i get sorted data from server.
all process work fine. but when restore layout using PersistenceManager, Column that user already sorted on it restore and data sorted in local mode, not server mode.
Therefore if GridView Sorting event raise automatic or manual after restore layout, my problem will be solved.
Note: I also using below code, but not work:
lstGridView.ForEach(p =>
{
if
(p.SortDescriptors !=
null
&& p.SortDescriptors.Count > 0)
{
p.RaiseEvent(
new
GridViewSortingEventArgs((p.SortDescriptors[0]
as
ColumnSortDescriptor).Column, SortingState.None, SortingState.Ascending) {
RoutedEvent = RadGridView.SortingEvent,
Source =
this
});
}
});
Could you please help me.