Pages

Thursday, August 19, 2010

Win32 command line free PDF to PDF/A converter

Similar to the previous entry for Linux type machines. Note 8.71 seems to be
more stable than 8.64 Ghostscript. Ghostscript 8.70 had problems


GET : http://sourceforge.net/projects/ghostscript/files/GPL%20Ghostscript/8.71/gs871w32.exe/download

GET java runtime or SDK

Files needed:
Fixflag (see April post)- java programs to turn 'on' print flags in each hyperlink.
PDFA_def.ps (see April post)- PDFA postcript def file
pdfmarks (see April post) - file containing metadata. edit this to put in your values.
USWebCoatedSWOP.icc (see April post)- color def file
test.bat contains ghost script command and parameters


To Preserve Hyperlinks and turn print flag on, run first:

java -cp C:\pdftest\Fixflag\pdfbox.jar:C:\pdftest\Fixflag\commons-logging.jar:. FixPrintFlag Input.pdf Output.pdf

then run test.bat
-------------------------------------------------------------

Otherwise
Run: test.bat

-------------------------------------------------------------
Contents of test.bat:
"C:\Program Files\gs\gs8.71\bin\gswin32c.exe" -sDEVICE=pdfwrite -q -dNOPAUSE -dBATCH -dNOSAFER -dPDFA -dUseCIEColor -sProcessColorModel=DeviceCMYK -sOutputFile=pdfa_out.pdf PDFA_def.ps pdfmarks c:\pdftest\test2.pdf
Note: make sure to change name of file in test.bat to match input and output names.

No comments:

Post a Comment