Link to home
Start Free TrialLog in
Avatar of sebadlington
sebadlingtonFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Can Ghostscript convert a Jpg file into a PDf?

Hi Guys,

 I need to convert some jpg files into PDF. I've been using Ghostscript to do it the other way as in PDF to Jpeg which works fine.

I have this dos batch file so far which will create me a bunch of PDF files but they are all empty and I get a bunch of errors as it goes through them

@echo off
if %1.==Sub. goto %2
for %%f in (C:\PODExpect\*.jpg) do call %0 Sub action %%~nf
goto end
:action

gswin32c.exe -q -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=C:\PODExpect\%3.pdf C:\PODExpect\%3.jpg -c quit

:end

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Joe Winograd
Joe Winograd
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of sebadlington

ASKER

works a treat - I'd used Irfan before but not downloaded the Plugins! Job done

Thanks

Seb
Thanks CodeCruiser - I'd already tried that link but without much success, the Irfan route is nice and easy ;)

Cheers
Seb,
You're welcome. IrfanView is a great piece of software! Cheers, Joe