How to call the system printer in a command line?

If you want to print a number of pdf documents in batch using command lines, the tool of VeryPDF PDFPrint will be a good choice. VeryPDF PDFPrint is a software for printing pdf documents in command line mode for Microsoft Windows Systems. Running in MS-DOS command line mode, PDFPrint supports to define almost all of the settings for an ordinary system printer. This article will present some option usages of PDFPrint in command lines.

You can download the package of PDFPrint from http://goo.gl/bC7UN and unpack it into any directory you preferred. In the directory, the executable file “pdfprint.exe” is the key component of the software. In this article, the commands are for executing in the MS-DOS command line prompt window running in the directory of the executable file. A basic usage of the program is

pdfprint.exe readme.pdf <Enter>,

in which, “pdfprint.exe” is the executable file and “readme.pdf” is the pdf document to be printed. Without any options, the system default printer will be used for printing this document. There is a method of launching the dialog of choosing printer to change the printer at http://goo.gl/bXJKm. The following example will use an option to determine to use which printer in the command line.

As presented in the coming snapshot, there are four printers in the author’s Windows System and the default one is a virtual printer named “Microsoft XPS Document Writer”.

image

The following commands use the option “-printer” to specify a printer for printing the document.

pdfprint -printer "docPrint" readme.pdf <Enter>

will call the system printer, “docPrint”, to print the pdf document, “readme.pdf”. The following snapshot displays the whole printing process.

image

Another option of “-copies” is for specifying how many copies to make in the printing. For example, the following command line will print the pdf document into three copies using the printer “docPrint PDF Driver”.

pdfprint -copies 3 -printer "docPrint PDF Driver" readme.pdf <Enter>,

where option “-copies” followed with argument “3” tells the printer “docPrint PDF Driver” specified by option “-printer” to print the pdf document “readme.pdf” into 3 copies.

The option “-paper” is for specifying the paper size to print to, and it has three types of argument, “pdf”, “number” and “others”. The argument “pdf” tells the printer to use the paper size of the pdf document, “number” specifies the predefined paper size using an integer (find the corresponding number of a paper size in a look-up-table at http://goo.gl/EGV9T), and “others” is for using customized paper sizes, such as "612x792pt", "11x17in", and "215.9x279.4mm". Below are there command lines using the three different types of arguments for defining the printing paper sizes.

pdfprint –paper pdf readme.pdf <Enter>

uses the paper size of the pdf document of “readme.pdf”,

pdfprint –paper 9 readme.pdf <Enter>

uses the paper size of A4 (represented by the integer 9), and

pdfprint –paper 612x792pt readme.pdf <Enter>

uses the paper size, width of 612 points and height of 792 points.

VN:F [1.9.20_1166]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.20_1166]
Rating: 0 (from 0 votes)

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!