jQuery UI Widgets › Forums › Grid › how to do "Save Changes" operation
This topic contains 4 replies, has 2 voices, and was last updated by Dimitar 12 years, 2 months ago.
-
Author
-
i am using Grid Widget to Show data
using like:[WebMethod]
[ScriptMethod(UseHttpGet = true, ResponseFormat = ResponseFormat.Xml)]
public static string GetCharts()now i wanna use Edit Mode of Grid
but after edit any value of grid how do i send the changed data to asp.net code behind to save changes ?
is there any example for this
in my mind puting a button to save changes :/
Hello epkr,
Please check out the tutorial Cells editing with jqxGrid and ASP.NET MVC3 and the other guides in the ASP .NET Integration section in the Documentation. We hope they are helpful to you.
Best Regards,
DimitarjQWidgets team
http://www.jqwidgets.com/Thanks for reply.
i got my solution in a different way because of i am not using MVC.
i send my data to codebehind using Ajax POST
code sample like this:
function saveChanges(objList) { var objList = new Array(); var rows = $("#jqxgrid").jqxGrid('getrows'); for(var i = 0; i < rows.length; i++) { objList.push(new Array(rows[i].ObjectID,rows[i].ParameterName,rows[i].ParameterValue,rows[i].isActive)); } $.ajax({ type: "POST", url: "XXXXX.aspx/SaveData", data: "{'data':'" + JSON.stringify(objList) + "'}", contentType: "application/json; charset=utf-8", dataType: "json", success: function (msg) { alert(msg.d); } }); }Now i am working on geting rows which edited by the user and i will update them.
i hope you understand what i wanna do on pure asp.net not MVC.
is there any sample like this 🙂 before i run on it 🙂Thanks.
Hi epkr,
Unfortunately, we do not have an ASP.NET CRUD example.
Best Regards,
DimitarjQWidgets team
http://www.jqwidgets.com/ -
AuthorPosts
You must be logged in to reply to this topic.