I have a folder with a few PDF files, each with multiple pages. I'm trying to get them all to print at once with custom parameters i.e. amount of pages per sheet (6), but can't seem to figure out the correct script. I'm new to acrobat scripting, How can I accomplish this? Thanks
Copy link to clipboard
Read the documentation of the PrintParams object for more details, but here's the basic code to do it:
var pp = this.getPrintParams(); pp.printerName = "Enter the printer name here"; pp.interactive = pp.constants.interactionLevel.silent; pp.pageHandling = pp.constants.handling.nUp; pp.nUpPageOrders = pp.constants.nUpPageOrders.Vertical; pp.nUpNumPagesH = 3; pp.nUpNumPagesV = 2; pp.nUpPageBorder=true; pp.nUpAutoRotate=true; this.print(pp);
Also how can I set a destination folder if I want it to print to a file? cant seem to find that in the guide.
ah. so it must physically print?
No, you can send the file to a virtual printer, but you can't specify the file-name or folder where it will be saved. That's up to the user.
So where will it print? will it show a prompt for the user? ive seent here is a way to silent print. is that possible?
Yes, it will prompt the user to enter the file name for each file.
The silent printing command only applies to showing the Print dialog, not to this.