Convertion of PDF to Scanned PDF/ Image only PDF

Hi everyone,

I’m working on a project where I need to convert PDF files to scanned PDFs or image-only PDFs because the software im doing automation on only accepts scanned PDFs. I’m using UiPath to automate this process, but I’m having some trouble getting the desired output.

Hey @Supreme_Secret ,

Welcome to the community!

I can suggest you this:

  1. Get the page count from pdf file using Get PDF Page Count Activity.
  2. Create a docx file using word activities.
  3. Use a loop to iterate through all the pages, inside the loop
    3.1 Use Export PDF Page as Image.
    3.2 Save this page in a temporary folder as image
    3.3 Use insert image to Word, Hit Page Break ( Ctrl+ Enter)
    3.4 Delete image from temp directory.
  4. Loop through all the pages
  5. Save document as PDF activity would convert your docx file to PDF.

This is the solution which I can think for now.

regards,
Aditya

Hello @Supreme_Secret

You can try below steps

  1. Perform OCR on the PDF: This activity will convert the PDF into scanned or image-only format by recognizing the text and creating a new PDF with images.

  2. Save the converted PDF: Add a “Write PDF Text” activity to save the converted PDF. Specify the output file path and provide the input text variable from the OCR activity.

  3. Run the workflow: Save your workflow and run it to convert the PDF to a scanned or image-only PDF.

Try this

In the “Manage Packages” window, search for “UiPath.PDF.Activities” and install the package.

Drag and drop the “Read PDF Text” activity from the “UiPath.PDF.Activities” package to the workflow.

In the properties panel of the “Read PDF Text” activity, select the PDF file that you want to convert.

Add an “Export to PDF” activity from the “UiPath.PDF.Activities” package to the workflow.

In the properties panel of the “Export to PDF” activity, choose the destination folder and file name for the output PDF.

Under the “Image Options” section, select the “Image Only” option to convert the PDF to an image-only PDF, or select the “Image with Searchable Text” option to convert the PDF to a scanned PDF.

Click on the “Save” button to save the workflow, and then run the workflow to convert the PDF to a scanned PDF or image-only PDF.

Try this