Free Support Forum - aspose.com

Embedded document images not appearing after conversion. PPTX to PDF

Basically when I have a powerpoint document with some embedded documents that are displayed as picture, after I convert to PDF the images disappear on the linux server but stay there when I convert on Windows.
aspose pptx to pdf.zip (300.0 KB)

Is there a simple fix for this?

@jshields3_baml_com

Thank you for contacting support.

Would you please share a narrowed down sample application reproducing this problem, along with environment details (JDK/JRE versions, Linux version, Windows version etc) so that we may try to reproduce and investigate it further. Before sharing requested data, please ensure using Aspose.PDF for Java 18.6 in your environment.

Sample code

package convertors;
import com.aspose.slides.PdfOptions;
import com.aspose.slides.Presentation;
import com.aspose.slides.SaveFormat;
import com.aspose.slides.FontsLoader;

public class PowerPointToPDF extends Convertor {

    public String convert(String input)
        throws Exception {
        //ExStart:ConvertingPresentationToPDFIncludingHiddenSlides
        Presentation pres = new Presentation(input);
        try {
            // Instantiate the PdfOptions class
            PdfOptions pdfOptions = new PdfOptions();
            // Load the fonts from custom folder
            FontsLoader.loadExternalFonts(new String[]{this.fonts});
            // Specify that the generated document should include hidden slides
            pdfOptions.setShowHiddenSlides(true);
            //pdfOptions.setSaveMetafilesAsPng(true);
            String out_fname = this.mktemppdf();
            // Save the presentation to PDF with specified options
            pres.save(out_fname, SaveFormat.Pdf, pdfOptions);
            return out_fname;

        } finally {
            pres.dispose();
        }

    }
}

Windows 7
linux : Redhat 7
JDK 1.8

@jshields3_baml_com,

I have worked with presentation file shared by you using Aspose.Slides for Java 18.7 on my end and have not been able to observe the issue when working in Windows. I suggest you to please try using suggested version. For your kind reference, generated PDF is also attached.

generated.pdf (55.9 KB)

This is not a Windows issue. This happens when my code is running on the Linux server. We want the Icons to stay there like they do when you convert using office. The disappear when converted on the linux server. We are using Redhat 7.

@jshields3_baml_com,

Thank you for sharing the information. An issue with ID SLIDESJAVA-37290 has been created in our issue tracking system to further investigate and resolve the issue. This thread has been linked with the issue so that you may be notified once the issue will be investigated and fixed for RedHat Linux.

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