Windows Server 2003 in a Nutshell

prncnfg new in WS2003

Displays information about printers and configures them.

Syntax

prncnfg -g -s RemoteComputer -p PrinterName prncnfg -t -s RemoteComputer -p PrinterName [-r PortName ] [-h ShareName ] [-i DefaultPriority ] ... [{+ -}{direct published shared workoffline ...}]

Options

-g

Displays printer settings

-s RemoteComputer

Name of print server.

-t

Configures printer.

-p PrinterName

Name of printer.

-r PortName

COM, LPT, or TCP/IP port of printer.

-h ShareName

Share name of printer.

-i DefaultPriority

Default priority for new jobs.

direct

Prints directly to printer (doesn't spool).

published

Publishes printer in Active Directory.

shared

Shares printer on network.

workoffline

Users can submit jobs to print queue even if their computers are offline.

Examples

Display information about printer named SalesPrinter managed by local computer:

prncnfg -g -p SalesPrinter Microsoft (R) Windows Script Host Version 5.6 Copyright (C) Microsoft Corporation 1996-2001. All rights reserved. Server name Printer name SalesPrinter Share name Driver name HP Color LaserJet Port name LPT1: Comment Location Separator file Print processor WinPrint Data type RAW Parameters Priority 1 Default priority 0 Printer always available Attributes local shared published enable_bidi do_complete_first Printer status Idle Extended printer status Unknown Detected error state Unknown Extended detected error state Unknown

Share SalesPrinter with share name SPRT :

prncnfg -t -p SalesPrinter -h SPRT +shared Microsoft (R) Windows Script Host Version 5.6 Copyright (C) Microsoft Corporation 1996-2001. All rights reserved. Configured printer SalesPrinter

Verify the result:

prncnfg -g -p SalesPrinter Microsoft (R) Windows Script Host Version 5.6 Copyright (C) Microsoft Corporation 1996-2001. All rights reserved. Server name Printer name SalesPrinter Share name SPRT <---NOTE Driver name HP Color LaserJet Port name LPT1: Comment Location Separator file Print processor WinPrint Data type RAW Parameters Priority 1 Default priority 0 Printer always available Attributes local shared enable_bidi do_complete_first Printer status Idle Extended printer status Unknown Detected error state Unknown Extended detected error state Unknown

Notes

See Also

Printing , prndrvr , prnjobs , prnmngr , prnport , prnqctl

Категории