I am learning jquery tables for a report.I am getting api response all fine.But i am unable to bind it to the jquery datatable.Looked many questions/examples similar to this.I am getting json data from ajax call.In my case i am passing three params
to my web service.
Web Service
[WebMethod]
[ScriptMethod(ResponseFormat = ResponseFormat.Json)]
public void GetDepositAccountStatement(long accountNumberId,
string fromDate, string toDate)
{
var frmDate = DatabaseLayer.Core.DateConversion.GetEnglishDate(fromDate).ToDateTime();
var tDate = DatabaseLayer.Core.DateConversion.GetEnglishDate(toDate).ToDateTime();
var res = BusinessLayer.Deposit.DepositAccountStatement.GetDepositAccountStatementViews(accountNumberId,
frmDate,
JavaScriptSerializer js = new JavaScriptSerializer();
Context.Response.Write(js.Serialize(res));
}
Member
34 Points
158 Posts
Unable to bind Json data in jquery datatable with correct data
Jul 24, 2018 09:46 AM|tarun02|LINK
I am learning jquery tables for a report.I am getting api response all fine.But i am unable to bind it to the jquery datatable.Looked many questions/examples similar to this.I am getting json data from ajax call.In my case i am passing three params to my web service.
Web Service
This WebService returns this Json
In my case i want to bind the data to the datatable on button click.Js code
And the html
On button click i am unable to get the data and bind to the datatable. Help Please.