WatchDirectory home page
WatchDirectory Startseite (Deutsche Version)
Site WatchDirectory (Français)
  Welcome, Guest. Please Login or Register
YaBB - Yet another Bulletin Board
   
  HomeHelpSearchLoginRegister  
 
Page Index Toggle Pages: 1
PDF Fit To Page (Read 2276 times)
AndyH
YaBB Newbies
*
Offline



Posts: 1
PDF Fit To Page
Aug 16th, 2007 at 8:36am
 
Hi all,

Can I modify my batch file so that it forces acrobat to fit the document to the printable area prior to printing it?

What other options are available to pass to acrobat? (/p /h etc....)

Thanks in advance

Andy
Back to top
 
 
IP Logged
 
Gert
YaBB Administrator
*****
Offline



Posts: 2232
The Netherlands
Re: PDF Fit To Page
Reply #1 - Aug 16th, 2007 at 11:04am
 
Hello Andy,

Acrobat doesn't have a commandline option for that - it is quite limited. If you want all PDF's resized to, for example, 80% of their original size you could use ImageMagick to do that: http://www.imagemagick.org/script/index.php

Change the wd.bat file found in the directory
<task directory>\<yourtaskname>

<task directory>: press CTRL+9 inside the watchDirectory Control Center to explore this directory
<yourtaskname>: the name of your task

Use notepad to open wd.bat, and find the following lines
Code:
"%GDPUTIL%" -runkill %SECONDS% "%ACROCMD%" %OPTIONS% "%WD_FILE%"
%ANNOTATE% Info done
 



Now change this to
Code:
SET WKDIR=C:\Temp
"C:\Program Files\ImageMagick\convert.exe" -resize 80% "%WD_FILE%" "%WKDIR%\%WD_FILE_N%"
"%GDPUTIL%" -runkill %SECONDS% "%ACROCMD%" %OPTIONS% "%WKDIR%\%WD_FILE_N%"
%ANNOTATE% Info done
 



This will create a new (resized) PDF in the C:\Temp directory (make sure that directory is not monitored by WD), and print that PDF instead.

Hope this helps,

Gert
Back to top
 

Gert Rijs - gert (at) gdpsoftware (dot) com
Blog: http://blog-en.gdpsoftware.com/
End Alzheimer's: http://www.alz.org&&...
WWW WWW GdPSoftware  
IP Logged
 
Page Index Toggle Pages: 1