How to convert multiple images into a single pdf file

A N M Bazlur Rahman

2021/06/10

Tags:              

I had some images that I needed had to export as pdf. I looked in the app store to find a free tool that makes it possible for me. However, after a quick search, I was not satisfied with the result. The Apps that support such things come at a hefty price tag. Then it hits me. Why not I write a few lines of java code and export pdf with ITextPdf library.

Well, that’s it. Five minutes of working helped me to save quite a few bucks.

Here is what I have got -

100DaysOfProgramming_Day004

for copy/paste pleasure: https://gist.github.com/rokon12/85705a4abe04cd572774bebdf76aebb7
I have used ITextPdf library for this purpose, and the dependency is-

implementation group: 'com.itextpdf', name: 'itextpdf', version: '5.5.13.2'

Categories:  

Share on: