Prndrvr command in Windows

(Applies to Windows Server (Semi-Annual Channel), Windows Server 2016, Windows Server 2012 R2, Windows Server 2012)

(Applies to Windows Server (Semi-Annual Channel), Windows Server 2016, Windows Server 2012 R2, Windows Server 2012)

The prndrvr command is used to add, delete and list printer drivers.

Syntax prndrvr command

 cscript prndrvr {-a | -d | -l | -x | -?} [-m] [-v {0 | 1 | 2 | 3}] 
[-e] [-s] [-u] [-w]
[-h] [-i]

Prndrvr command parameter

Parameters

Describe

-a

Install the driver.

-d

Delete a driver.

-l

List all printer drivers installed on the server specified by the -s parameter.If you do not specify a server, Windows will list the printer drivers installed on the local computer.

-x

Delete all additional printer drivers and printer drivers that are not used by a logical printer on the server specified by the -s parameter.If you do not specify a server to remove from the list, Windows will delete all unused printer drivers on the local computer.

-m

Specify (by name) the driver you want to install.Drivers are usually named after the type of printer they support.Please review the printer's documentation for more details.

3}

Specify the driver version you want to install.See the description of the parameter for information about which version will be available for which environment.If you do not specify a version, the version of the driver that matches the version of Windows running on the computer on which you are installing the driver will be installed by default.

  1. Version 0 supports Windows 95, Windows 98 and Windows Millennium edition.
  2. Version 1 supports Windows NT 3.51.
  3. Version 2 supports Windows NT 4.0.
  4. Version 3 supports operating systems including Windows Vista, Windows XP, Windows 2000 and Windows Server 2003. Note that this is the only printer driver version that Windows Vista is supported.

-e

Specify the environment for the driver you want to install.If you do not specify the environment, the environment of the computer on which you are installing the driver will be used by default.Supported environment parameters are:

  1. "Windows NT x86"
  2. "Windows x64"
  3. "Windows IA64"

-S

Specify the name of the remote computer that the printer store you want to manage.If you do not specify a remote computer, the local computer will be used by default.

-u -w

Specify an account that has the right to connect to the printer storage computer that you want to manage.All members in the local administrator group of the specified computer have these rights, but the permissions can also be granted to other users.If you do not specify an account, you must log in to an account with these permissions so that the command can be executed.

-hour

Specify the path to the driver file.If you do not specify a path, the path to the location where Windows is installed will be used by default.

-i

Specify the full path and file name for the driver you want to install.If you do not specify a file name, the script will use one of the .inf files in theinfsubdirectory of the Windows directory.

If the path to the driver is not specified, the script will look for the driver files in the driver.cab file.

/?

Show help at the command prompt.

Note prndrvr command

The prndrvr command is a Visual Basic script located in the% WINdir% System32printing_Admin_Scripts directory. To use this command, at the command prompt, type cscript followed by the full path to the prndrvr file, or change the directory to the appropriate directory.

For example:

 cscript% WINdir% System32printing_Admin_Scriptsen-USprndrvr 

If the information you provide contains spaces, use quotation marks for the text (for example, "computer Name").

The -x option will delete all additional printer drivers (the driver is installed for use on clients running alternate versions of Windows), even if the main driver is available. use.If the fax is installed, this option will also delete the fax drivers.The main fax driver will be deleted if it is not used (ie if there are no queues used, it will be deleted).If the main fax driver is deleted, the only way to re-enable the fax is to reset the fax component.

If used without parameters, prndrvr displays command line help for prndrvr command.

For example, prndrvr command

To list all the drivers on the server named printServer1, type:

 cscript Prndrvr -l -s 

To add the Windows x64 printer driver version 3 to the "Laser printer model 1"printer modelof the printer by using the driver information file at C: tempLaserprinter1.inf, enter the following command:

 cscript Prndrvr -a -m "Laser printer model 1" -v 3 -e "Windows x64" -ic: tempLaserprinter1.inf -hc: temp 

To delete Windows NT x86 version 3printerdriver for "Laser printer model 1", enter:

cscript Prndrvr -a -m "Laser printer model 1" -v 3 -e "Windows NT x86"

See more:

  1. The print command in Windows
  2. The net print command in Windows
  3. Netcfg command in Windows
  4. Nbtstat command in Windows
4.5 ★ | 2 Vote