Hi
I am loading a spreadsheet with the help of a dataset result. I have a stored procedure that output's the result to a dataset and this dataset is being loaded to a datatable and rendered on the speadsheet using datasource. Below is my code
public ActionResult Products_Load([DataSourceRequest]DataSourceRequest request) { DataTable dt = new DataTable(); dt.Clear(); DataSet dsGetData = HandlerUtilities.HandlerFunctions.GetDynamicSheetData(1, 4); if (dsGetData != null) { dt = dsGetData.Tables[0]; } dt.Columns.Remove("atUserid"); dt.Columns.Remove("atTimestamp"); dt.AcceptChanges(); DataSourceResult result = dt.ToDataSourceResult(request); JsonResult oJsonResult = Json(result, JsonRequestBehavior.AllowGet); return oJsonResult; }
When the data is rendered on the spreadsheet, the datetime values are getting converted into /Date(xxxxxx)/ instead of original values. I have attached the screenshot of my output for reference. My dataset is dynamic and everytime it will get changed and due to this I am not using a view model to bind the data. Hence, I cant provide the fieldname and its format in the client side as I dont know what the fieldnames will be. Is there any workaround fr this?
