Showing posts with label sorting. Show all posts
Showing posts with label sorting. Show all posts

Wednesday, March 28, 2012

asp.net Ajax datagrid?

Hi,

I am looking for a tutorial sort of thing that can guide me to build ajax enabled datagrid with functionalities like editing,deleting, sorting, paging etc in ajax mode. Right now I am able to load the datagrid ajax way but not able to find way to get other things in ajax manner. any help will be appreciated.

Regards,

Sunil

Hi Sunil,

Maybe this link can be helpfull:

http://weblogs.asp.net/rajbk/archive/2007/01/17/master-details-using-ajax-introducing-the-updatepanelpopupextender.aspx

regards,


Hi Dennis,

Thanks for your link but it is not what i want. I want that I should be doing all sort of things (editing, sorting,deleting) in grid with the help of ajax. If user does any sorting, then page should not get posted back and use ajax. same for other functionalities.I have searched google for it but didnot find any good help.

Regards,

Sunil


Maybe you just need an <asp:GridView> control inside an <asp:UpdatePanel>? (Then all the sorting/paging/editing/etc. will go through the server, but asynchronously and without reloading the page. That's the magic of the UpdatePanel!)

Monday, March 26, 2012

ASP.NET AJAX + JSON: Custom Grid with paging + sorting

Hi,

I am looking for the following solution:

I replaced myUpdatePanel with a client-side PageMethod to a Webservice webmethodusing ASP.NET Ajax and JSON serialization. I now want to use some kindof data table to display my result, however I also need Paging +Sorting.

Using asp:GridView is not a solution here since it is a server-side control with server-side sorting functionality.

Any suggestions? I don't want some heavy JS file that can do this.

You can add two more parameters to your "webmethod" - something like pageNumber and sortString. If I understood you correctly.


Yep. I am just wondering how to construct this whole thing. So far I am thinking of passing the sortDirection, and perform the sorting on the server side directly since I am dealing with a List. The paging is a little trickier though.


hello.

for paging, you just need to pass the current page and the number of elements per page. you should perform paging on the server side and only return the neecessary elements.


Thank youGeeked


What did you end up using for your solution? You mentioned a GridView was not an option... are you constructing the table by hand?