Save Excel to PDF

Hi,

I have written a very simple console application to export an excel file to PDF, but application is taking for ever to export to pdf. It has already run for about and hour still no success.
Can you please help?

The excel file is 5.14 MB and has 115996 rows.

Stopwatch sw = new Stopwatch();
sw.Start();
Workbook book = new Workbook(“xyz.xlsx”);
book.Save(Path.ChangeExtension(book.FileName, “pdf”), SaveFormat.Pdf);
sw.Stop();
Console.WriteLine(sw.ElapsedMilliseconds);
Console.ReadKey();


Hi Ricky,

Thanks for your posting and using Aspose.Cells.

Please download and try the latest version: Aspose.Cells for .NET 8.2.1 and see if it resolves your issue.

If your issue still occurs, then please provide us your source Excel file which you are converting to PDF. We will try to convert your Excel file into PDF at our end and in case, it is a bug, we will log it in our database for a fix.

Hi,
Thanks for the reply.
I used the latest version 8.2.1 but same result. The application ran for 3 odd hours before it generated the PDF.
Attaching the excel that I used.

HI Ricky,


Thank you for providing the sample spreadsheet.

We are able to observe the performance lag while converting your sample spreadsheet to PDF format while using the code snippet as provided below.

C#

LoadOptions options = new LoadOptions();
options.MemorySetting = MemorySetting.MemoryPreference;
Workbook workbook = new Workbook(myDir + “xyz.xlsx”, options);
workbook.Save(myDir + “output.pdf”, SaveFormat.Pdf);

We have logged an investigative ticket CELLSNET-43015 to look further into this matter. Please spare us little time to properly analyze the problem cause, and to provide a fix. In the meanwhile, we will keep you posted with updates in this regard.

Hi,

Thanks for your using Aspose.Cells.

We have fixed this issue.

Please download and try the latest fix: Aspose.Cells for .NET v8.2.1.4 and let us know your feedback.

Thanks for the fix. Its now generating the file in under 10 mins.
Is the same fix also done on the JAVA api. If yes which version should I download?


Hi,

Thanks for your feedback and using Aspose.Cells.

It is good to know that your issue is resolved with the latest fix. Let us know if you encounter any other issue, we will be glad to look into it and help you further.

You may try the latest Java version by downloading it from this link: Aspose.Cells
for Java v8.2.1.4
. Let us know your run results.

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


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