A System.OutOfMemoryException always occurs in my program when the input data size becomes larger. Basically my program uses Xceed DataGrid i am trying to do Export 6000 records with 12 columns to XPS Document.
if(xceeddataGrid.ExportToXps(stream, pageSize, imageableArea, pageRange, CompressionOption.SuperFast, ExporttoXPSCallback, true, false))
Here i am getting OutOfMemoryException. i want to cancel export when memory is low using ExporttoXPSCallBack.
Please help me come out of it.