I have a grid that has a property of Boolean type, as I can show it in "Active", "Inactive" according to whether it is true or false, besides that I need
export it to excel passing the values of "Active" and "Inactive"
Stay tuned.
Regards!| [C#] public ActionResult ExportToExcel(string GridModel) { ExcelExport exp = new ExcelExport(); var DataSource = order.ToList(); GridProperties obj = (GridProperties)Syncfusion.JavaScript.Utils.DeserializeToModel(typeof(GridProperties), GridModel); obj.ServerExcelQueryCellInfo = QueryCellInfo; GridExcelExport excelExp = new GridExcelExport(); excelExp.FileName = "Export.xlsx"; excelExp.Excelversion = ExcelVersion.Excel2010; excelExp.Theme = "flat-saffron"; return exp.Export(obj, DataSource, excelExp); } public void QueryCellInfo(object currentCell) { IRange range = (IRange)currentCell; if (range.Column == 5) { if(range.Value == "TRUE") range.Value = "Active"; else range.Value = "InActive"; } } |