Hi,
I need to pass an argument to the method in the URL, please provide me the syntax for the same, i have pasted my code below.
My .net method in URL – GetCompaness expects an argument.
var source1 = { datatype: "json", datafields: dataFields, data : gid, url: 'Company/GetCompanies', id: 'CompanyId', addrow: function (rowid, rowdata, position, commit) { // synchronize with the server - send insert command // rowdata.GroupCompanyId = gid; //datarow.CompanyId = (ctr + 1); $.ajax ({ cache: false, dataType: 'json', url: 'Company/Add', data: rowdata, type: "POST", success: function (data, status, xhr) { // insert command is executed. commit(true); }, error: function (jqXHR, textStatus, errorThrown) { alert("err" + errorThrown); commit(false); } }); },
Thanks,
Keshavan