I would like to create a trusted function to print a particular document to the Adobe PDF printer -- and I would like to capture a filename and specify a particular path.
I have a document level function which performs this task, using the print params object and printing to pdf. But I can't specify a file name or path -- which is why I'd like to created a trusted function.
I created a trusted function to save a document to a specific location and that works fine.... but I can't seem to get the print to pdf function to work.
Is it possible to print to pdf specifying the filename and path?
There is a possibility though. If the "fileName" property is specified and print driver name is left blank the PDF will print to postscript. Then you can convert the postscript file to PDF by opening it in Acrobat. Like this:
This code can only be run from a trusted function.
Thom Parker
The source for PDF Scripting Info
[url=http://www.pdfScripting.com]pdfscripting.com[/url]
The Acrobat JavaScript Reference, Use it Early and Often
[url=http://www.adobe.com/devnet/acrobat/]http://www.adobe.com/devnet/acrobat/[/url]
Thom Parker
The source for PDF Scripting Info
www.pdfscripting.com
Very Important - How to Debug Your Script