Commandline printing

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?
LVL 5
paulqnaAsked:
Who is Participating?
 
jkrConnect With a Mentor Commented:
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
 
jkrCommented:
You could try

cscript c:\windows\system32\prnmngr.vbs -t "Adobe PDF"
print drive:\path\to\filename
0
 
paulqnaAuthor Commented:
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
 
paulqnaAuthor Commented:
The first command works but then the print command fails with this message:

Unable to initialize device PRN
0
 
paulqnaAuthor Commented:
Problem never solved.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.