public void ExcelExport() { PivotChartExcelExport pivotChartExcelExport = new PivotChartExcelExport(); string args = System.Web.HttpContext.Current.Request.Form.GetValues(0)[0]; Dictionary <string, string> chartParams = serializer.Deserialize <Dictionary <string, string> >(args); pivotChartExcelExport.ExportToExcel(chartParams); }
protected void PivotChart_ServerExcelExporting(object sender, Syncfusion.JavaScript.Web.PivotChartEventArgs e) { PivotChartExcelExport pivotChartExcelExport = new PivotChartExcelExport(); dynamic args = e.Arguments; Dictionary <string, string> chartParams = serializer.Deserialize <Dictionary <string, string> >(args["args"].ToString()); pivotChartExcelExport.ExportToExcel(chartParams); }
public ActionResult ExportToExcel() { PivotChartExcelExport pivotChart = new PivotChartExcelExport(); var context = _contextAccessor.HttpContext; var args = context.Request.Form.ElementAt(0).Value; Dictionary <string, string> clientParams = JsonConvert.DeserializeObject <Dictionary <string, string> >(args); clientParams["fileName"] = "sample"; return(pivotChart.ExportToExcel(clientParams)); }