Python 3 Script to Generate PDF From Multiple JPEG Images Using jpg2pdf Module Full Project For Beginners

 

In order to get started you need to install the below module by using the pip command as shown below

 

 

pip install jpg2pdf

 

 

After installing this module you need to make an main.py file and copy paste the following code

 

 

main.py

 

 

import jpg2pdf

with jpg2pdf.create('test.pdf') as pdf:
    pdf.add('1.jpg')
    pdf.add('2.jpg')
    pdf.add('3.jpg')

 

Leave a Reply