The Syncfusion native Blazor components library offers 70+ UI and Data Viz web controls that are responsive and lightweight for building modern web apps.
.NET PDF framework is a high-performance and comprehensive library used to create, read, merge, split, secure, edit, view, and review PDF files in C#/VB.NET.
In GridGroupingControl 2.0.5.1
If a user sorts a column, can I disable the behavior that keeps the grid sorted when changes are made?
i.e., if I sort by column X, and then begin changing the values in column X, the grid keeps sorting. I want to sort Once and force the user to click the column again to sort again, instead of keeping it sorted with each change.
Any ideas?
ADAdministrator Syncfusion Team September 28, 2005 11:19 PM UTC
Hi,
The grid structures require to have the records always be sorted according to the sort order. Otherwise things will get out of sync.
The only way you can get this working is if you do not let the grid engine do the sorting.
What you could do is have your own implementation of an IBindingList. This IBindingList should be filled with the data that you want to display in the grid.
You could then listen to the click event on the column header and then do a custom sorting yourself.
When you handle the sort you could then manually sort your list and after that raise a ListChangedType.Reset event so that the grid knows the records were changed.
You should not modify the grid SortColumns collection.
If you do it this way the grid will simply display the records in the order as they are in your custom list and when you change contents of a record or add a record it will not need to sorted.
It will hoevever not work if you also require grouping columns ...
Stefan
>In GridGroupingControl 2.0.5.1
>
>If a user sorts a column, can I disable the behavior that keeps the grid sorted when changes are made?
>
>i.e., if I sort by column X, and then begin changing the values in column X, the grid keeps sorting. I want to sort Once and force the user to click the column again to sort again, instead of keeping it sorted with each change.
>
>Any ideas?
>