Article View: adobe.acrobat.sdk
Article #36How to print to PDF without a print dialog box
From: Dale Fox
Date: Fri, 13 Nov 2009 00:15
Date: Fri, 13 Nov 2009 00:15
42 lines
2836 bytes
2836 bytes
I need to print to the "Adobe PDF" print driver and have the PDF file created without user interaction. The purpose is to have a programming language print a series of reports to PDF files automatically. So I need a way to suppress the print dialog box that normally appears when you print to the "Adobe PDF" print driver and also to specify a destination name. Note that the destination name does not need to be unique to each file; if I can have all PDFs that are generated go to the same destination folder and filename that is fine. We have Adobe Distiller 7.0, Adobe Acrobat 7.0 Professional and Adobe Designer 7.0. The print driver is called "Adobe PDF". I thought the joboptions file might handle this, but there is no option for filename. I thought the following registry keys could do this, but they seem to control only the default destination folder, rather than allowing a folder and filename. HKEY_LOCAL_MACHINE\SOFTWARE\Adobe\Acrobat Distiller\7.0\DefaultPDFOutput HKEY_CURRENT_USER\Software\Adobe\Acrobat Distiller\PrinterJobControl I tried setting the following attributes within the programming language. The print did then proceed without displaying the print dialog box, but the resulting PDF files are unusable; Acrobat reports them as corrupted when I try to open them. - FileName (sets path and name for the file to be created by the printer) - DocumentName (sets name to be displayed in the Printer status dialog that lists the files being printed on the printer) - PrinterName (sets the name of the Windows printer to print to) Note that setting these three attributes does allow printing to succeed with Amyuni PDF print driver. (We are going away from Amyuni due to instability issues.) Any hints would be appreciated. Thanks. Dale
Technical Details
Message-ID:
<4AFCA538.2010701@foxcustomsoftware.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post01.iad.highwinds-media.com!newsfe21.iad.POSTED!7564ea0f!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Thread: dbdca6ad55,4879aaf06554d0d9,start X-Google-Attributes: giddbdca6ad55,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: arc1-ca.pugleaf.net!g2news1.google.com!news1.google.com!npeer01.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post01.iad.highwinds-media.com!newsfe21.iad.POSTED!7564ea0f!not-for-mail Message-ID: <4AFCA538.2010701@foxcustomsoftware.com> From: Dale Fox <dale.ng11@foxcustomsoftware.com> User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 Newsgroups: adobe.acrobat.sdk,adobe.acrobat.windows Subject: How to print to PDF without a print dialog box Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Lines: 42 NNTP-Posting-Host: 68.146.13.67 X-Complaints-To: internet.abuse@sjrb.ca X-Trace: newsfe21.iad 1258071348 68.146.13.67 (Fri, 13 Nov 2009 00:15:48 UTC) NNTP-Posting-Date: Fri, 13 Nov 2009 00:15:48 UTC Date: Thu, 12 Nov 2009 17:15:52 -0700