We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Aspose.Cell.Exception caused by pdf conversion

Hi everybody,

the attached xls document can’t be saved as pdf file. An AsposeCell.Exception is thrown.

.net runtime 3.5

Example Code:

string strSourceFile = @“c:\Temp\Test_xls.xls”;
string strLicFile = @“c:\Temp\Aspose-2015.Total.lic”;

Aspose.Cells.License license = new Aspose.Cells.License();

LoadOptions loadOpt= new LoadOptions(LoadFormat.Auto);
loadOpt.MemorySetting = MemorySetting.MemoryPreference;

Workbook wb = new Workbook(strSourceFile, loadOpt);

PdfSaveOptions saveOpt= new PdfSaveOptions();
saveOpt.Compliance = PdfCompliance.None;

string strDestFile = Path.ChangeExtension(strSourceFile, “.pdf”);
wb.Save(strDestFile, saveOpt);

Best regards, Martin


Thanks for your posting and using Aspose.Cells.

We were able to observe this issue by executing your sample code with the latest version: Aspose.Cells
for .NET v8.6.1.2
. However we found that if you comment memory preference setting as shown in the following code, then this exception does not occur.

We have therefore logged this issue relating to exception caused by memory preference setting in our database for investigation. We will look into it and fix this issue. Once the issue is resolved or we have some other update for you, we will let you know asap.

This issue has been logged as

  • CELLSNET-44055 - Aspose.Cell.Exception caused by pdf conversion because of memory preference setting

Please try the following code to generate your pdf without memory preference setting successfully.

string filePath = @“D:\Downloads\Test_xls.xls”;

LoadOptions loadOpt = new LoadOptions(LoadFormat.Auto);
// loadOpt.MemorySetting = MemorySetting.MemoryPreference;

Workbook wb = new Workbook(filePath, loadOpt);

PdfSaveOptions saveOpt = new PdfSaveOptions();
saveOpt.Compliance = PdfCompliance.None;

wb.Save(“output.pdf”, saveOpt);

Hi again,

This is to inform you that we have fixed the problem logged earlier as CELLSNET-44055. We will shortly provide the fix here after ensuring the quality and incorporating other enhancements. As soon as the next build of Aspose.Cells for .NET is available for your testing, we will notify you here in reference to aforementioned ticket.


Please try our latest version/fix: Aspose.Cells for .NET v8.6.3.2 (attached).

We have fixed your issue now.

Let us know your feedback.

Thank you.

The issues you have found earlier (filed as CELLSNET-44055) have been fixed in this update.

This message was posted using Notification2Forum from Downloads module by Aspose Notifier.