Comandos Impressoras CMD
Comandos Impressoras CMD
Comandos Impressoras CMD
Syntax
Copy
rundll32 printui.dll PrintUIEntry [BaseParameter] [ModificationParameter1]
[ModificationParameter2] [ModificationParameterN]
You can also use the following alternate syntaxes, although the examples in this
topic use the previous syntax:
Copy
rundll32 printui.dll,PrintUIEntry [BaseParameter] [ModificationParameter1]
[ModificationParameter2] [ModificationParameterN]
Copy
rundll32 printui PrintUIEntry [BaseParameter] [ModificationParameter1]
[ModificationParameter2] [ModificationParameterN]
Copy
rundll32 printui,PrintUIEntry [BaseParameter] [ModificationParameter1]
[ModificationParameter2] [ModificationParameterN]
Parameters
There are two types of parameters: base parameters and modification parameters.
Base parameters specify the function that the command is to perform. Only one of
these parameters can appear in a given command line. Then, you can modify the base
parameter by using one or more of the modification parameters if they are
applicable to the base parameter (not all modification parameters are supported by
all base parameters).
Examples
To add a new remote printer, printer1, for a computer, Client1, which is visible
for the user account where this command is run, type:
Copy
rundll32 printui.dll PrintUIEntry /in /n\\client1\printer1
To add a printer using the add printer wizard and using an .inf file, InfFile.inf,
located on drive c: at Infpath, type:
Copy
rundll32 printui.dll PrintUIEntry /ii /f c:\Infpath\InfFile.inf
To delete an existing printer, printer1, on a computer, Client1, type:
Copy
rundll32 printui.dll PrintUIEntry /dn /n\\client1\printer1
To add a per computer printer connection, printer2, for all users of a computer,
Client2, type (the connection will be applied when a user logs on):
Copy
rundll32 printui.dll PrintUIEntry /ga /n\\client2\printer2
To delete a per computer printer connection, printer2, for all users of a computer,
Client2, type (the connection will be deleted when a user logs on):
Copy
rundll32 printui.dll PrintUIEntry /gd /n\\client2\printer2
To view the properties of the print server, printServer1, type:
Copy
rundll32 printui.dll PrintUIEntry /s /t1 /c\\printserver1
To view the properties of a printer, printer3, type:
Copy
rundll32 printui.dll PrintUIEntry /p /n\\printer3
___________________________________________________________________________________
_____
***********************************************************************************
*****
Exemplos:
Executar as propriedades do servidor:
rundll32 printui.dll,PrintUIEntry /s /t1 /c\\computador
Executar as propriedades da impressora:
rundll32 printui.dll,PrintUIEntry /p /n\\computador\impressora
Executar o Assistente para Adicionar Impressora localmente:
rundll32 printui.dll,PrintUIEntry /il
Execute o assistente para adicionar impressora em \\machine:
rundll32 printui.dll,PrintUIEntry /im /c\\machine
Executar a exibi��o de fila:
rundll32 printui.dll,PrintUIEntry /o /n\\computador\impressora
Executar a instala��o do arquivo INF:
rundll32 printui.dll,PrintUIEntry /if /b "Test Printer" /f
c:\infpath\infFile.inf /r "lpt1:" /m "Brother DCP-128C"
Executar a instala��o de inf (com depend�ncia de inf). No exemplo, prnbr002.inf
depende de ntprint.inf
rundll32 printui.dll, PrintUIEntry /ia /m "Brother DCP-128C" /K /h x64 /v 3 /f
"c:\infpath\prnbr002.inf" /F "c:\infpath\ntprint.inf"
Executar o Assistente para Adicionar Impressora usando inf:
rundll32 printui.dll,PrintUIEntry /ii /f C:\infpath\infFile.inf
Adicionar a impressora usando driver de impressora da caixa de entrada:
rundll32 printui.dll,PrintUIEntry /if /b "Test Printer" /r "lpt1:" /m "Brother DCP-
128C"
Adicionar conex�o de impressora por computador (a conex�o ser� propagada ao
usu�rio ap�s o logon):
rundll32 printui.dll,PrintUIEntry /ga /c\\computador /n\\computador\impressora
/j"Servi�os de impress�o LanMan"
Excluir conex�o de impressora por computador (a conex�o ser� exclu�da ap�s o
logon do usu�rio):
rundll32 printui.dll,PrintUIEntry /gd /c\\computador /n\\computador\impressora
Enumerar as conex�es de impressora por computador:
rundll32 printui.dll,PrintUIEntry /ge /c\\computador
Adicionar o driver da impressora usando inf:
rundll32 printui.dll,PrintUIEntry /ia /c\\computador /m "Brother DCP-128C" /h "x86"
/v "Type 3 - User Mode" /f c:\infpath\infFile.inf
Adicionar o driver da impressora usando inf:
rundll32 printui.dll,PrintUIEntry /ia /K /c\\computador /m "Brother DCP-128C" /h
"x86" /v 3
Adicionar o driver de impressora de caixa de entrada:
rundll32 printui.dll,PrintUIEntry /ia /c\\computador /m "Brother DCP-128C" /h
"Intel" /v "Type 3 - Kernel Mode"
Remover o driver de impressora:
rundll32 printui.dll,PrintUIEntry /dd /c\\computador /m "Brother DCP-128C" /h "x86"
/v "Type 3 - User Mode"
Remover o driver de impressora:
rundll32 printui.dll,PrintUIEntry /dd /K /c\\computador /m "Brother DCP-128C" /h
"x86" /v 3
Definir a impressora como padr�o:
rundll32 printui.dll,PrintUIEntry /y /n "printer"
Definir coment�rio da impressora:
rundll32 printui.dll,PrintUIEntry /Xs /n "impressora" coment�rio "Minha impressora"
Obter configura��es de impressora:
rundll32 printui.dll,PrintUIEntry /Xg /n "printer"
Obter os resultados de salvamento das configura��es da impressora em um arquivo:
___________________________________________________________________________________
_____________________________________
***********************************************************************************
*************************************
Command Description
[lpq]lpq.md) Displays the status of a print queue on a
computer running Line printer Daemon (LPD).
lpr Sends a file to a computer or printer sharing device
running the Line printer Daemon (LPD) service in preparation for printing.
Net print Displays information about a specified printer queue,
displays information about a specified print job, or controls a specified print
job.
print Sends a text file to a printer.
prncnfg Configures or displays configuration
information about a printer.
prndrvr adds, deletes, and lists printer drivers.
prnjobs pauses, resumes, cancels, and lists print jobs.
prnmngr adds, deletes, and lists printers or printer
connections, in addition to setting and displaying the default printer.
prnport creates, deletes, and lists standard TCP/IP
printer ports, in addition to displaying and changing port configuration.
prnqctl prints a test page, pauses or resumes a
printer, and clears a printer queue.
pubprn Publishes a printer to the active directory
directory service.
rundll32 printui.dll,printUIEntry Enables you to automate the installation and
configuration of printers using scripts or the command prompt.
/c[nome] nome unc da m�quina caso a a��o seja em uma m�quina remota
/h[arch] a arquitetura do driver � uma das seguintes: Alpha | Intel | IA64 | x64
/k imprime p�gina de teste para a impressora especificada, n�o pode ser usado com
comando ao instalar uma impressora
2 PRINTER_INFO_2
7 PRINTER_INFO_7
c Color Profile
d PrinterData
s Security descriptor
g Global DevMode
m Minimal settings
u User DevMode
f Force name
p Resolve port
/Z compartilha esta impressora; pode ser usada apenas com a op��o /if
Exemplos: