Conversion from docx to PDF with TIFF Image

Hi - is there a way to convert a Word document containing a TIFF image to a PDF without losing the image? I’m attaching an example document. Thanks.

Hi Richard,

Thanks for your inquiry. Yes, you can convert Word document to Pdf without losing image using Aspose.Words. Please use following code example to convert Word document to Pdf and use latest version of Aspose.Words for Java 15.11.0.

Document doc = new Document(MyDir + "FigureError.docx");
doc.save(MyDir + "Out.pdf");

Hi Tahir

Thanks for your quick response. I upgraded to 15.11.0 (from 15.10.0) as you suggested and ran the above code, but I still get the same result (the TIFF image doesn’t show). I enclose the resulting PDF.

Thanks, Richard

Ah - I hadn’t realised that Aspose.Words had a JAI dependancy. I’ve added thew following Maven artifact to my project and the TIFF images now convert:

<dependency>
    <groupId>com.github.jai-imageio</groupId>
    <artifactId>jai-imageio-core</artifactId>
    <version>1.3.1</version>
</dependency>

Please note that the links on the Aspose page https://docs.aspose.com/words/java/system-requirements/ are dead.

Ah - I hadn’t realised that Aspose.Words had a JAI dependancy. I’ve added the following Maven artifact to my project and the TIFF images now convert:

<dependency>
    <groupId>com.github.jai-imageio</groupId>
    <artifactId>jai-imageio-core</artifactId>
    <version>1.3.1</version>
</dependency>

Please note that the links on the Aspose page https://docs.aspose.com/words/java/system-requirements/ are dead.

Hi Richard,

Thanks for your feedback. It is nice to hear from you that your problem has been solved. We will fix the broken links in shared documentation link. Please feel free to ask if you have any question about Aspose.Words, we will be happy to help you.