Solved

Commandline printing

Posted on 2007-11-23
5
535 Views
Last Modified: 2010-04-21
I want to create PDF documents using the "PDF Printer" as installed by AcrobatPro7 via the windows commandline.

Now an XP dos box allows you to use the print command but when you try:

print /D:"Adobe PDF" drive:\path\to\filename

Where "Adobe PDF" is the actual printer name (also by default).

This does not work as the print command does not understand which printer to use.

What command should I give to tell the print command to use the Adobe PDF printer?
0
Comment
Question by:paulqna
  • 3
  • 2
5 Comments
 
LVL 86

Expert Comment

by:jkr
ID: 20340560
You could try

cscript c:\windows\system32\prnmngr.vbs -t "Adobe PDF"
print drive:\path\to\filename
0
 
LVL 5

Author Comment

by:paulqna
ID: 20341122
Executing that cscript command gives me the help text for the prnmngr.vbs, so I think there is a syntax problem with that command?
0
 
LVL 86

Accepted Solution

by:
jkr earned 500 total points
ID: 20341205
Ah, that should be

cscript c:\windows\system32\prnmngr.vbs -t -p "Adobe PDF"
print drive:\path\to\filename

It actually sets the standard printer.
0
 
LVL 5

Author Comment

by:paulqna
ID: 20341239
The first command works but then the print command fails with this message:

Unable to initialize device PRN
0
 
LVL 5

Author Closing Comment

by:paulqna
ID: 31410707
Problem never solved.
0

Featured Post

Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Over the years I have built up my own little library of code snippets that I refer to when programming or writing a script.  Many of these have come from the web or adaptations from snippets I find on the Web.  Periodically I add to them when I come…
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question