Srinivas Dhulipala
Top achievements
Rank 1
Srinivas Dhulipala
asked on 06 Feb 2012, 03:58 PM
Hi,
Below is my requirement:
I have a RadGrid with 10 columns. I need Client Side Sorting of all the columns without Screen Refresh or Postback.
I have this Radgrid in a USer Control which is being used in many pages.
I tried some of the approaches shown in the various threads in this forum, but all of them resulted in postback.
Can you please send me a working sample of how this can be accomplished.
Thanks
Srinivas Dhulipala
Below is my requirement:
I have a RadGrid with 10 columns. I need Client Side Sorting of all the columns without Screen Refresh or Postback.
I have this Radgrid in a USer Control which is being used in many pages.
I tried some of the approaches shown in the various threads in this forum, but all of them resulted in postback.
Can you please send me a working sample of how this can be accomplished.
Thanks
Srinivas Dhulipala
6 Answers, 1 is accepted
0
Shinu
Top achievements
Rank 2
answered on 07 Feb 2012, 05:24 AM
0
Princy
Top achievements
Rank 2
answered on 07 Feb 2012, 05:35 AM
Hello,
Take a look into the following forum thread which discussed the same.
client side paging and sorting of RadGrid
Thanks,
Princy.
Take a look into the following forum thread which discussed the same.
client side paging and sorting of RadGrid
Thanks,
Princy.
0
Dan
Top achievements
Rank 1
answered on 11 Aug 2016, 12:04 AM
It seems to me that the Question is pretty straightforward:
"How to Achieve Client Side Sorting without Postback" but what the user (and myself) is really trying to achieve is re-sorting the array without retrieving the data again.
Both of the responses here send the user to threads or examples that insist on do declarative binding which is just another way of getting the data again.
It would appear to me that there is no Built in way to do this with Telerik Rad Controls. I suspect this has to do with the fact that the entire Grid is ajaxified and as such requires a postback?
Can we please get an Admin person that really understands this to give us a straightforward answer?
0
Hello Dan,
When binding your grid on server-side, it requires postback every time you initiate a rebinding action like Paging, Sorting, Filtering, etc. In order to optimize performance and improve greatly user responsiveness, you can ajaxify the grid. You can do that using RadAjaxManager or RadAjaxPanel:
http://docs.telerik.com/devtools/aspnet-ajax/controls/ajaxmanager/overview
http://docs.telerik.com/devtools/aspnet-ajax/controls/ajax/radajaxpanel/overview
You can check various live samples to see it in practice:
http://demos.telerik.com/aspnet-ajax/grid/examples/functionality/paging/basic-paging/defaultcs.aspx
Alternatively, you can bind your grid entirely on client-side:
http://demos.telerik.com/aspnet-ajax/grid/examples/data-binding/client-side/client-data-source-binding/defaultcs.aspx
To wrap it up, it depends on your chosen binding approach. If the binding is server-side, a full PostBack or ajaxified partial CallBack must be done to the server to get the data anew. If the binding is client-side, you can update the grid using only javascript, without rendering the page all over.
I hope this will prove helpful.
Regards,
Eyup
Telerik by Progress
When binding your grid on server-side, it requires postback every time you initiate a rebinding action like Paging, Sorting, Filtering, etc. In order to optimize performance and improve greatly user responsiveness, you can ajaxify the grid. You can do that using RadAjaxManager or RadAjaxPanel:
http://docs.telerik.com/devtools/aspnet-ajax/controls/ajaxmanager/overview
http://docs.telerik.com/devtools/aspnet-ajax/controls/ajax/radajaxpanel/overview
You can check various live samples to see it in practice:
http://demos.telerik.com/aspnet-ajax/grid/examples/functionality/paging/basic-paging/defaultcs.aspx
Alternatively, you can bind your grid entirely on client-side:
http://demos.telerik.com/aspnet-ajax/grid/examples/data-binding/client-side/client-data-source-binding/defaultcs.aspx
To wrap it up, it depends on your chosen binding approach. If the binding is server-side, a full PostBack or ajaxified partial CallBack must be done to the server to get the data anew. If the binding is client-side, you can update the grid using only javascript, without rendering the page all over.
I hope this will prove helpful.
Regards,
Eyup
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
0
Dan
Top achievements
Rank 1
answered on 15 Aug 2016, 04:09 PM
Hi Eyup,
So, succinctly, one cannot re-sort the Grid without Rebinding!
So, succinctly, one cannot re-sort the Grid without Rebinding!
0
Hi Dan,
Yes, of course. The grid records should be refreshed in order to update their position, depending on the chosen sort mode (ASC, DESC, None) and field.
Regards,
Eyup
Telerik by Progress
Yes, of course. The grid records should be refreshed in order to update their position, depending on the chosen sort mode (ASC, DESC, None) and field.
Regards,
Eyup
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.