Converting an XLS file containing a shape with a gradient background to PDF caused an error

We’re using Aspose.Cell to convert Excel documents to PDF files and we encountered an issue that it caused an error when I converted some XLS files to PDF files.


Attached please find a sample XLS file I created to reproduce this issue. The code is something like:

Workbook workbook = new Workbook(fromPath);
workbook.Save(toPath, Aspose.Cells.SaveFormat.Pdf);

And I got an exception:

Aspose.Cells.CellsException: Shape to image Error!
Location Aspose.Cells.Workbook.Save(String fileName, SaveOptions saveOptions)
Location Aspose.Cells.Workbook.Save(String fileName, SaveFormat saveFormat)

I tested this issue with Aspose.Cell for .NET 7.6.1.0, Visual Studio 2012.

Best Regards

Hi Satoshi,

Thanks for your posting and using Aspose.Cells.

When your file is opened in MS-Excel 2010, it shows warning, so it seems there is some problem with your source file. When it is converted to pdf using Aspose.Cells, it throws exception. We have logged this issue in our database. 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-42213.

Do you have any updates on this issue?


I’ve tested with Aspose.Cells 7.7.2 and it still has the issue.

Hi Satoshi,

I am afraid, the ticket logged as CELLSNET-42213 isn’t resolved yet. We have inquired about the recent updates regarding this issue from the concerned development team member. As soon as some news comes in, we will post here for your kind reference.

Thank you for your patience.

Hi,

Thanks for using Aspose.Cells.

Please download and try this fix: Aspose.Cells
for .NET v8.0.1.3
and let us know your feedback.

Tested with this version and it now doesn’t throw an exception, although the result PDF looks ugly. I attached both the original XLS and the converted PDF.

Hi,


Thanks for the sample files.

I have tested your scenario/ case a bit. The issue is still there as you mentioned. The formatting of the shape is scattered / disordered. I have reopened your issue “CELLSNET-42213” again. We will look into your issue soon.

Thank you.

Hi,

Thanks for your using Aspose.Cells.

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

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


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