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

Free Support Forum - aspose.com

Aspose.Slides PPTX to PDF with embedded charts

I’m trying to convert a PPTX to PDF with embedded charts but I am getting a NullReference exception. My code is as follows:

WriteLogMessage($"{convDoc.FileExtension} Conversion.", log, Enumerations.LogLevel.Information);

                                        Aspose.Slides.License slidesLic = new Aspose.Slides.License();

                                        WriteLogMessage("Creating in memory Aspose document from the memory stream.", log, Enumerations.LogLevel.Information);
                                        Presentation presentation = new Presentation(inMemStrm);

                                        WriteLogMessage("Saving Aspose document as PDF to output memory stream.", log, Enumerations.LogLevel.Information);

                                        Aspose.Slides.Export.PdfOptions slideSaveOptions = new Aspose.Slides.Export.PdfOptions();

                                        slideSaveOptions.SaveMetafilesAsPng = true;
                                        slideSaveOptions.JpegQuality = (byte)100;
                                        slideSaveOptions.TextCompression = Aspose.Slides.Export.PdfTextCompression.Flate;
                                        slideSaveOptions.SufficientResolution = 300;

                                        slideSaveOptions.Compliance = Aspose.Slides.Export.PdfCompliance.PdfA1b;

                                        presentation.Save(outMemStrm, Aspose.Slides.Export.SaveFormat.Pdf, slideSaveOptions);

If I remove the charts from the source file they convert without issue.

Hi James,

Can you please share source presentation so that we can further investigate issue in details to help you out.

Best Regards,


I can’t share the exact file we have had issues with for commercial reasons, but I created a new presentation with a chart in it and I have the same issues. I have attached this one.



Hi James,

I have worked with your source presentation. I am unable to observe the issue. I have shared generated result for your kind reference. I have also shared my source code with you in a text file. Please share feedback with us if there is still an issue.

Best Regards,