Aspose.Slides 20.11 Throws Exceptions While Trying to Process Links to Charts

  1. We process many PPTX files simultaneously.
  2. PPTX files seem to have many Excel chart links pointing to the same file.
  3. The linked Excel file is in a network share (we do not know if it’s required for reproducing the error or not).
  4. Whenever we call “Save” method in Aspose.Slides (Aspose.Slides.Presentation.Save(String fname, SaveFormat format)), sometimes sharing violation exception happens when Aspose tries to deal with those chart links and our PPTX file is being saved back as an empty file. We lose all PPTX file’s data. We have reported this in Calling "Save" Method in Aspose.Slides 20.11 Leads to Losing Data in PPTX Files .
  5. Sometimes, Aspose.Slides throws sharing violation error also when we try to process this chart links in LFA (we call Aspose.Slides.Charts.ChartData.SetExternalWorkbook(String workbookPath)). Since it’s not happening inside their “Save” method, this time we are not getting empty file in the output, but those issues can be connected with each other and we think they should get fixed.

@vikram.venugopal,
Thank you for contacting support.

There were many updates after version 20.11. Please check your results using the latest version of Aspose.Slides if it possible. If the issue persists, please share/describe the following:

  • code example that reproduces the problem
  • presentation and Excel files you used
  • conditions to reproduce the problem with the shared file

@andrey.potapov, resurrecting this support ticket again after 3 years. We are now able to reproduce this issue with Aspose.Slides 25.5.

We created a sample project to test this issue out.
AsposeCorruptFilesOnSave.7z (49.4 KB)

It contains the 2 projects, running the MainApp would do everything needed.
When the issue is fixed, it should show 0 zero-size files:
image.png (2.7 KB)

@vikram.venugopal,
Thank you for the sample project. I need some time to check the issue. I will get back to you as soon as possible.

@vikram.venugopal,
Thank you for your patience. I’ve reproduced the exceptions you described.

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): SLIDESNET-45006

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

The issues you found earlier (filed as SLIDESNET-45006) have been resolved in Aspose.Slides for .NET 25.7 (ZIP, MSI, NuGet, Cross-platform).
You can check all fixes on the Release Notes page.
You can also find the latest version of our library on the Product Download page.

@vikram.venugopal,
Please note that you can use the IChartData.SetExternalWorkbook(newTargetPath, false) method if you only want to replace the workbook link without updating the chart data.