Page 1 of 1
Rev for PDF printing?
Posted: Wed Nov 21, 2007 1:38 pm
by activa
I've got a client who wants a simple product: a CD with PDFs, and a front end to print them. I'm sure I can do it with Rev, but is it the best tool? Can I do it directly from Acrobat directly? (I have v8 pro) If I do it from Rev, do I have to use rev to open Acrobat and then print?
Posted: Wed Nov 21, 2007 9:14 pm
by Janschenkel
Hi Activa,
While Revolution can't do it natively, you can combine it with other tools to achieve the goal.
For Windows you can use "pdfp" - a command-line tool to print PDF files - as long as there's an Acrobat Reader installed on the client computer.
You can download the pdfp.zip package (including C source code) here:
http://www.esnips.com/doc/9e2a3a72-52ca ... 5f02f/pdfp
Then you can execute a silent shell command to print the PDF file:
Code: Select all
on mouseUp
answer file "Select a PDF file to print"
if it is empty then exit mouseUp
put revWindowsFromUnixPath(it) into tFilePath
put "pdfp.exe" && tFilePath into tCommand
put the hideConsoleWindows into tSaveHCW
set the hideConsoleWindows to true
get shell(tCommand)
set the hideConsoleWindows to tSaveHCW
end mouseUp
On Mac, you can use AppleScript to tell the Finder to print the PDF file:
Code: Select all
on mouseUp
answer file "Select a PDF file to print"
if it is empty then exit mouseUp
put revMacFromWindowsPath(it) into tFilePath
put "tell application" && quote & "Finder" & quote && \
"to print file" && quote & tFilePath & quote \
into tCommand
do tCommand as AppleScript
end mouseUp
Turning the above into a general-purpose cross-platform handler is left as an exercise to the reader
Hope this helped,
Jan Schenkel.
Posted: Thu Nov 22, 2007 6:12 pm
by BvG
For windows there's also the open source
pdf creator. It installs a software printer, which you can talk to like a normal printer.