On the grid, columns are dragged and reordered. When a user clicks one of the column headers to sort it after they have been reordered, they go back to the order they were orginally presented when the grid loaded for the first time. On the first post back from the sort everything is in it's proper place however each subsequent time the order is lost.
Thanks
Thanks
4 Answers, 1 is accepted
0
Kevin Babcock
Top achievements
Rank 1
answered on 28 Dec 2008, 01:42 PM
Hi Ryan,
If you want to maintain the order of the columns of your RadGrid across postbacks, you should perform the reordering on the server. You can easily accomplish this by setting RadGrid's ClientSettings.ReorderColumnsOnClient property to false.
I hope this helps. Let me know if you need some additional help.
Regards,
Kevin Babcock
If you want to maintain the order of the columns of your RadGrid across postbacks, you should perform the reordering on the server. You can easily accomplish this by setting RadGrid's ClientSettings.ReorderColumnsOnClient property to false.
<ClientSettings |
AllowColumnsReorder="true" |
ReorderColumnsOnClient="false"> |
</ClientSettings> |
I hope this helps. Let me know if you need some additional help.
Regards,
Kevin Babcock
0
Ryan
Top achievements
Rank 1
answered on 30 Dec 2008, 01:47 PM
I don't think I described this correctly. A user orders the columns to their liking, this new order needs to presist across multiple postbacks. Setting ReorderColumnsOnClient="false" makes the columns go back to the order they appeared on the first load and ReorderColumnsOnClient="true" works only for 1 postback, for example, when a user sorts the first time it appears correctly, when they sort the second time it performs as if it was ReorderColumnsOnClient="false" . It needs to perform like ReorderColumnsOnClient="true" except that it needs to keep working across multiple postbacks, not just one. In the demos I've seen this works correctly however it isn't working in my grid, maybe there is a conflicting property?
0
Hi Ryan,
I tested the behavior that you mentioned, and the conrol behaved as expected.
Attached to this message, is the code, which I used for testing.
Take a look at it and let me know if I am leaving something out.
All the best,
Yavor
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
I tested the behavior that you mentioned, and the conrol behaved as expected.
Attached to this message, is the code, which I used for testing.
Take a look at it and let me know if I am leaving something out.
All the best,
Yavor
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
DogBizPro
Top achievements
Rank 1
answered on 12 Jan 2018, 05:34 PM
I have the exact same issue that the column order is being reset when posted back. These settings do not help.