How do I print my PDF file to Windows Printer from command line without need Adobe Reader?

VeryPDF PDF Print Command Line item is actually a skilled item to print the PDF file to Windows Printer from command line, it is not like Adobe Reader application, PDF Print Command Line is design for Command Line application only, you are able to call it from your source code or script or .bat file to batch print your PDF files to Windows Printer on the fly.

https://www.verypdf.com/pdfprint/index.html#dl

Adobe Reader does not support command line printing really well, Adobe Reader is very slow, which makes a poor way to print batch PDF files.

Please refer to following questions which come from other users:
================================================
You have the ability to display and print a PDF with Acrobat and Adobe Reader within the command line. These instructions are unsupported, but have worked for a lot of software developers. There is no documentation of user instructions for command line usage too.
-----------------------------------------------------------
Acrobat Reader - Print PDF as image (Command Line Choices)
-----------------------------------------------------------

Is it feasible to print a PDF as image utilizing Acrobat Reader via command line options?

Or this feature is only available by way of the GUI of Acrobat?
-----------------------------------------------------------
However for you, the answer is "No!". Printing PDF pages as an image is only available through the GUI in Acrobat Reader.
-----------------------------------------------------------
I'm having two problems when trying to print a pdf silently in C# making use of adobe acrobat. I'm printing the pdfs employing Process.Start().

The very first issue is that I cannot launch Adobe Acrobat with out specifying the full path to the executable. I assume it does not add it to your path once you install it. Is there an easy method to launch the newest version of acrobat on a machine without specifying full path names? I'm worried that the client is going to do an update and break my code that launches this. I'm also concerned with them installing this on machines with different versions of windows (install paths are diverse in 64 bit environment vs. 32 bit).

My second difficulty is the truth that whenever I launch acrobat and print it nonetheless leaves the acrobat window open. I thought that the command line parameters I was making use of would suppress all of this but apparently not.

I'm trying to launch adobe acrobat from the command line using the following syntax:

C:\Program Files (x86)\Adobe\Reader 10.0\Reader>AcroRd32.exe /t "Label.pdf" "HP4000" "HP LaserJet 4100 Series PCL6" "out.pdf"

It prints out fine but it nonetheless leaves the acrobat window up. Is there any other remedy besides going out and killing the method programmatically?
-----------------------------------------------------------
Difficulty 1:

You might have the ability to work your way around the registry. In HKEY_CLASSES_ROOT\.pdf\PersistentHandler\(Default) you ought to discover a CLSID that points to a value identified in one of two places. Either the CLSID folder of the identical key, or (for 64 bit systems) 1 step down in Wow6432Node\CLSID then in that CLSID's key.

Inside that key you are able to appear for LocalServer32 and locate the default string value pointing to the present exe path.

I'm not 100% on any of this, but seems plausible (although you are going to need to verify on multiple environments to confirm that in-fact locates the procedure you're trying to find).

(Here are the docs on registry keys involved relating to PersistentHandlers)

Difficulty 2:

Almost certainly making use of the CreateNoWindow of the Method StartInfo.

Method p = new Procedure();
p.StartInfo.FileName = @"C:\Program Files (x86)\Adobe\Reader 10.0\Reader\AcroRd32.exe";
p.StartInfo.Arguments = "/t \"Label.pdf\" \"HP4000\" \"HP LaserJet 4100 Series PCL6\" \"out.pdf\"";
p.CreateNoWindow = accurate;
p.Start();
p.WaitForExit();
(only a guess even so, but I'm certain a bit testing will prove it to work/not function)
-----------------------------------------------------------
I need to print pdf doc from command line in win xp / 2000 without having opening the file.
When I had acrobat reader 7.0 I could have accomplished this by this command:

"C:\Program Files\Adobe\Reader 8.0\Reader\AcroRd32.exe" /t /h /l "e:\test.pdf" "HP LJ 4350 PCL 5e"

When I installed acrobat reader 8.0 the switches \h \l isn't working.
The file is printed but it open and stays open.

I look in your web web site documentation for the new switches in acrobat reader 8.0 but with no luck.

Please help me
-----------------------------------------------------------
Is there a way to use Aodbe Reader to print a Pdf and set "Fit to Printable Area" option from command line? Once I attempt to print pdf files using command line it prints it at 100%, this is a problem because some files can't fit to printer's paper size.
------------------------------------

Sadly, "Fit to Printable Area" is not an option within the command line, Adobe Reader doesn't support this process within the command line. However, VeryPDF PDF Print Command Line option does support "Fit to Printable Area" option, you can download PDF Print Command Line application from following page to try,

https://www.verypdf.com/pdfprint/index.html#dl
-----------------------------------------------------------
You can also use Adobe Reader to print the PDF files from command line, please see some examples at below,

I believe your PDF printing techniques listed might not work nicely for a listing well over 50 PDF files, I'd a script using,

CALL START /MIN AcroRd32.exe /h /p [filename]

for each PDF in a list, but it stopped queuing them up at about the 35th-50th one (had a list of 90), depending on the computer. I think it is related to how memory is allocated with CALL START.
After a lot of troubleshooting, I found that you can FIRST launch Adobe Reader using

CALL START /MIN AcroRd32.exe /h

and then later in the script just call (without using CALL START)

AcroRd32.exe /h /p [filename]

for each file name, and it will allow execution to return to the batch file because Adobe Reader is already open. This worked well for printing/queuing up over 100 PDFs.

I tried your recent /T switch option for Reader 7 and it seemed to open a new instance of AcroRd32.exe for every PDF - not feasible when printing more than 10 PDFs. The downside is that without /T, one instance of AcroRd32.exe will still be left open after the script ends, albeit minimized.
-----------------------------------------------------------
How to Print to the PDF Command Line
-----------------------------------------------------------
1. Go to the "Start" menu of the computer,

2. Enter "cmd" in Run box and press Enter keyboard,

3. Enter AcroRd32.exe /t "C:\test.pdf" "\\servername\\printername" in your command prompt. Replace the information in quotes using the filename and destination from the file you wish to print, name of the server and also the name of the printer. This allows you to definitely print an evaluation file.

4. Push the "Enter" button in the CMD window. This prints the Pdf towards the printer that you simply specified.
-----------------------------------------------------------
VN:F [1.9.20_1166]
Rating: 7.9/10 (8 votes cast)
VN:F [1.9.20_1166]
Rating: +1 (from 1 vote)
How do I print my PDF file to Windows Printer from command line without need Adobe Reader?, 7.9 out of 10 based on 8 ratings

Related Posts

Leave a Reply

Your email address will not be published. Required fields are marked *


Verify Code   If you cannot see the CheckCode image,please refresh the page again!