je tente en vain de créer un script permettant la création d'une imprimante
bracnhé sur un server d'impression jet direct. Il faut donc pouvoir créer un
port tcp/ip.
J'ai trouvé ce script :
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2")
Set objNewPort = objWMIService.Get _
("Win32_TCPIPPrinterPort").SpawnInstance_
objNewPort.Name = "IP_169.254.110.14"
objNewPort.Protocol = 1
objNewPort.HostAddress = "169.254.110.14"
objNewPort.PortNumber = "9999"
objNewPort.SNMPEnabled = False
objNewPort.Put_mais il ne fonctionne qu'avec xp/2003.j'ai tenté de créer
l'imprimante manuellemen,t puis de reperer les cléfs de registre
correspodante, soit
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers.J'ai
exporté le fichier reg et executer sur autre machine. apres un reboot,
l'imprimante apparait. j'ai donc tenter de créer un batch avec regedit /s au
demarrage de la machine, et la ce n'est pas pris en compte meme apres
plusieurs reboot.Comment faire donc pour automatiser cette installation.
Pour rendre l'imprimante disponible, je l'ai partagé sur le server et
connecté apr script.merci beaucoup @ tousbonne journée.vanzetti44 ;)
Cette action est irreversible, confirmez la suppression du commentaire ?
Signaler le commentaire
Veuillez sélectionner un problème
Nudité
Violence
Harcèlement
Fraude
Vente illégale
Discours haineux
Terrorisme
Autre
technicland
vanzetti44 nous a dit :
je tente en vain de créer un script permettant la création d'une ("Win32_TCPIPPrinterPort").SpawnInstance_ mais il ne fonctionne qu'avec xp/2003. normal Win32_TCPIPPrinterPort
=>http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/win32_tcpipprinterport.asp Requirements Client: Requires Windows XP. Server: Requires Windows Server 2003.
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPrintPrinters.J'ai exporté le fichier reg et executer sur autre machine. apres un reboot, l'imprimante apparait. j'ai donc tenter de créer un batch avec regedit /s au demarrage de la machine, et la ce n'est pas pris en compte meme apres plusieurs reboot.Comment faire donc pour automatiser cette installation. Pour rendre l'imprimante disponible, je l'ai partagé sur le server et connecté apr script.merci beaucoup @ tousbonne journée.vanzetti44 ;)
Peut etre essayer avec un modele perso fichier .adm pour deployer les cles mais la technique d ajouter des clefs comme ca via le registre pour installer des choses, j ai pas trouve d autre methode via un xcript pour ajouter un port essaye sur le news scripting peut etre
-- Laurent www.technicland.com
vanzetti44 nous a dit :
je tente en vain de créer un script permettant la création d'une
("Win32_TCPIPPrinterPort").SpawnInstance_
mais il ne fonctionne qu'avec xp/2003.
normal Win32_TCPIPPrinterPort
=>http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/win32_tcpipprinterport.asp
Requirements
Client: Requires Windows XP.
Server: Requires Windows Server 2003.
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPrintPrinters.J'ai
exporté le fichier reg et executer sur autre machine. apres un reboot,
l'imprimante apparait. j'ai donc tenter de créer un batch avec
regedit /s au demarrage de la machine, et la ce n'est pas pris en
compte meme apres plusieurs reboot.Comment faire donc pour
automatiser cette installation. Pour rendre l'imprimante disponible,
je l'ai partagé sur le server et connecté apr script.merci beaucoup @
tousbonne journée.vanzetti44 ;)
Peut etre essayer avec un modele perso fichier .adm pour deployer les cles
mais la technique d ajouter des clefs comme ca via le registre pour
installer des choses, j ai pas trouve d autre methode via un xcript pour
ajouter un port essaye sur le news scripting peut etre
je tente en vain de créer un script permettant la création d'une ("Win32_TCPIPPrinterPort").SpawnInstance_ mais il ne fonctionne qu'avec xp/2003. normal Win32_TCPIPPrinterPort
=>http://msdn.microsoft.com/library/default.asp?url=/library/en-us/wmisdk/wmi/win32_tcpipprinterport.asp Requirements Client: Requires Windows XP. Server: Requires Windows Server 2003.
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPrintPrinters.J'ai exporté le fichier reg et executer sur autre machine. apres un reboot, l'imprimante apparait. j'ai donc tenter de créer un batch avec regedit /s au demarrage de la machine, et la ce n'est pas pris en compte meme apres plusieurs reboot.Comment faire donc pour automatiser cette installation. Pour rendre l'imprimante disponible, je l'ai partagé sur le server et connecté apr script.merci beaucoup @ tousbonne journée.vanzetti44 ;)
Peut etre essayer avec un modele perso fichier .adm pour deployer les cles mais la technique d ajouter des clefs comme ca via le registre pour installer des choses, j ai pas trouve d autre methode via un xcript pour ajouter un port essaye sur le news scripting peut etre
-- Laurent www.technicland.com
technicland
vanzetti44 nous a dit :
bonjour
je tente en vain de créer un script permettant la création d'une imprimante bracnhé sur un server d'impression jet direct. Il faut donc pouvoir créer un port tcp/ip.
J'ai trouvé ce script :
Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!" & strComputer & "rootcimv2") Set objNewPort = objWMIService.Get _ ("Win32_TCPIPPrinterPort").SpawnInstance_
Salut repondu sur Administration evite de multiposter ca fait repondre souvent dans le vide LAurent
vanzetti44 nous a dit :
bonjour
je tente en vain de créer un script permettant la création d'une
imprimante bracnhé sur un server d'impression jet direct. Il faut
donc pouvoir créer un port tcp/ip.
J'ai trouvé ce script :
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\" & strComputer &
"rootcimv2") Set objNewPort = objWMIService.Get _
("Win32_TCPIPPrinterPort").SpawnInstance_
Salut
repondu sur Administration evite de multiposter ca fait repondre souvent
dans le vide
LAurent
je tente en vain de créer un script permettant la création d'une imprimante bracnhé sur un server d'impression jet direct. Il faut donc pouvoir créer un port tcp/ip.
J'ai trouvé ce script :
Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!" & strComputer & "rootcimv2") Set objNewPort = objWMIService.Get _ ("Win32_TCPIPPrinterPort").SpawnInstance_
Salut repondu sur Administration evite de multiposter ca fait repondre souvent dans le vide LAurent
technicland
technicland nous a dit :
Salut repondu sur Administration evite de multiposter ca fait repondre
Sorry j avais pas vu le FU2
technicland nous a dit :
Salut
repondu sur Administration evite de multiposter ca fait repondre
Salut repondu sur Administration evite de multiposter ca fait repondre
Sorry j avais pas vu le FU2
vanzetti44
salut
j'ai trouvé ca sur le forum us scripting : rick wrote:
I have about 400 machines that I need to install printers to. I found a script for Windows Xp to install printers for, but I can't find anything to
do it for Windows 2000. It would be a big help if I could do this remotely.
But can it even be done. Thanks for the help. Hi
Take a look at prnadmin.dll in the MS Windows 2003 Server Resource Kit (can be used for Windows 2000 as well).
Windows Server 2003 Resource Kit Tools http://www.microsoft.com/downloads/details.aspx?FamilyID467a69-57ff-4ae7-96ee-b18c4790cffd&DisplayLang=en
(The kit will install on WinXP or later, but you can copy needed files over to a Win2k computer, and then run regsvr32.exe against prnadmin.dll)
More about PrnAdmin:
Printer Administration Objects (PrnAdmin) is a COM-based tool that provides large-scale, noninteractive control of printers, drivers, and ports on local and remote computers.
Using PrnAdmin, you can:
Add and delete a local or remote printer. Add and delete printer connections. Add and delete a local or remote form. Add and delete a local or remote standard TCP/IP port (of type Line Printer Remote (LPR) or RAW). Add and delete a local or remote driver. View a list of printers, ports, drivers, and forms on a local or remote computer. Control and configure a local or remote printer.
PrnAdmin consists of several scriptable COM objects residing in Prnadmin.dll, which functions as a wrapper around Printui.dll. Several Microsoft Visual Basic Script (VBScript) sample files are included with the tool.
Note
For more detailed information on how to use PrnAdmin.DLL, see Prnadmin.doc. This white paper provides additional information on printer, drivers, ports and forms to help administrators and programmers manage a large number of local and remote printers.
Corresponding Operating System Features
All the functionality of prnadmin.dll can be duplicated using the printers folder and various wizards. Converting printer ports from LPR to Standard TCP/IP is the only functionality in prnadmin.dll for which there is no corresponding GUI.
For more information about PrnAdmin and the Windows Management Instrumentation (WMI) scripts in Windows Server 2003, see Designing and Deploying Print Servers(http://go.microsoft.com/fwlink/?LinkIDG45) in the Windows Server 2003 Deployment Kit.
System Requirements
The following are the system requirements for this tool:
Windows 2000 or Windows Server 2003 operating systems.
Files Required
Prnadmin.dll Prnadmin.doc
The following sample VBScript files are also required:
Clean.vbs Clone.vbs (there is no WMI equivalent for the cloning script) Conall.vbs Defprn.vbs Drvmgr.vbs Forms.vbs Persist.vbs Portconv.vbs Portmgr.vbs Prncfg.vbs Prnctrl.vbs Prndata.vbs Prnmgr.vbs
Je teste et je vous dit ca
@+
-- torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway Administration scripting examples and an ONLINE version of the 1328 page Scripting Guide: http://www.microsoft.com/technet/scriptcenter/default.mspx
"technicland" a écrit dans le message de news:
vanzetti44 nous a dit :
je tente en vain de créer un script permettant la création d'une ("Win32_TCPIPPrinterPort").SpawnInstance_ mais il ne fonctionne qu'avec xp/2003. normal Win32_TCPIPPrinterPort
Requirements Client: Requires Windows XP. Server: Requires Windows Server 2003.
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPrintPrinters.J'ai exporté le fichier reg et executer sur autre machine. apres un reboot, l'imprimante apparait. j'ai donc tenter de créer un batch avec regedit /s au demarrage de la machine, et la ce n'est pas pris en compte meme apres plusieurs reboot.Comment faire donc pour automatiser cette installation. Pour rendre l'imprimante disponible, je l'ai partagé sur le server et connecté apr script.merci beaucoup @ tousbonne journée.vanzetti44 ;)
Peut etre essayer avec un modele perso fichier .adm pour deployer les cles mais la technique d ajouter des clefs comme ca via le registre pour installer des choses, j ai pas trouve d autre methode via un xcript pour ajouter un port essaye sur le news scripting peut etre
-- Laurent www.technicland.com
salut
j'ai trouvé ca sur le forum us scripting :
rick wrote:
I have about 400 machines that I need to install printers to. I found a
script for Windows Xp to install printers for, but I can't find anything
to
do it for Windows 2000. It would be a big help if I could do this
remotely.
But can it even be done. Thanks for the help.
Hi
Take a look at prnadmin.dll in the MS Windows 2003 Server Resource Kit
(can be used for Windows 2000 as well).
Windows Server 2003 Resource Kit Tools
http://www.microsoft.com/downloads/details.aspx?FamilyID467a69-57ff-4ae7-96ee-b18c4790cffd&DisplayLang=en
(The kit will install on WinXP or later, but you can copy needed
files over to a Win2k computer, and then run regsvr32.exe against
prnadmin.dll)
More about PrnAdmin:
Printer Administration Objects (PrnAdmin) is a COM-based tool that
provides large-scale, noninteractive control of printers, drivers,
and ports on local and remote computers.
Using PrnAdmin, you can:
Add and delete a local or remote printer.
Add and delete printer connections.
Add and delete a local or remote form.
Add and delete a local or remote standard TCP/IP port (of type
Line Printer Remote (LPR) or RAW).
Add and delete a local or remote driver.
View a list of printers, ports, drivers, and forms on a local or
remote computer.
Control and configure a local or remote printer.
PrnAdmin consists of several scriptable COM objects residing in
Prnadmin.dll, which functions as a wrapper around Printui.dll.
Several Microsoft Visual Basic Script (VBScript) sample files are
included with the tool.
Note
For more detailed information on how to use PrnAdmin.DLL, see
Prnadmin.doc. This white paper provides additional information on
printer, drivers, ports and forms to help administrators and
programmers manage a large number of local and remote printers.
Corresponding Operating System Features
All the functionality of prnadmin.dll can be duplicated using the
printers folder and various wizards. Converting printer ports from
LPR to Standard TCP/IP is the only functionality in prnadmin.dll
for which there is no corresponding GUI.
For more information about PrnAdmin and the Windows Management
Instrumentation (WMI) scripts in Windows Server 2003, see
Designing and Deploying Print
Servers(http://go.microsoft.com/fwlink/?LinkIDG45) in the
Windows Server 2003 Deployment Kit.
System Requirements
The following are the system requirements for this tool:
Windows 2000 or Windows Server 2003 operating systems.
Files Required
Prnadmin.dll
Prnadmin.doc
The following sample VBScript files are also required:
Clean.vbs
Clone.vbs (there is no WMI equivalent for the cloning script)
Conall.vbs
Defprn.vbs
Drvmgr.vbs
Forms.vbs
Persist.vbs
Portconv.vbs
Portmgr.vbs
Prncfg.vbs
Prnctrl.vbs
Prndata.vbs
Prnmgr.vbs
Je teste et je vous dit ca
@+
--
torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway
Administration scripting examples and an ONLINE version of
the 1328 page Scripting Guide:
http://www.microsoft.com/technet/scriptcenter/default.mspx
"technicland" <webmasterpasdepourriels@technicland.com> a écrit dans le
message de news:exVDspe3EHA.2012@TK2MSFTNGP15.phx.gbl...
vanzetti44 nous a dit :
je tente en vain de créer un script permettant la création d'une
("Win32_TCPIPPrinterPort").SpawnInstance_
mais il ne fonctionne qu'avec xp/2003.
normal Win32_TCPIPPrinterPort
Requirements
Client: Requires Windows XP.
Server: Requires Windows Server 2003.
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPrintPrinters.J'ai
exporté le fichier reg et executer sur autre machine. apres un reboot,
l'imprimante apparait. j'ai donc tenter de créer un batch avec
regedit /s au demarrage de la machine, et la ce n'est pas pris en
compte meme apres plusieurs reboot.Comment faire donc pour
automatiser cette installation. Pour rendre l'imprimante disponible,
je l'ai partagé sur le server et connecté apr script.merci beaucoup @
tousbonne journée.vanzetti44 ;)
Peut etre essayer avec un modele perso fichier .adm pour deployer les cles
mais la technique d ajouter des clefs comme ca via le registre pour
installer des choses, j ai pas trouve d autre methode via un xcript pour
ajouter un port essaye sur le news scripting peut etre
j'ai trouvé ca sur le forum us scripting : rick wrote:
I have about 400 machines that I need to install printers to. I found a script for Windows Xp to install printers for, but I can't find anything to
do it for Windows 2000. It would be a big help if I could do this remotely.
But can it even be done. Thanks for the help. Hi
Take a look at prnadmin.dll in the MS Windows 2003 Server Resource Kit (can be used for Windows 2000 as well).
Windows Server 2003 Resource Kit Tools http://www.microsoft.com/downloads/details.aspx?FamilyID467a69-57ff-4ae7-96ee-b18c4790cffd&DisplayLang=en
(The kit will install on WinXP or later, but you can copy needed files over to a Win2k computer, and then run regsvr32.exe against prnadmin.dll)
More about PrnAdmin:
Printer Administration Objects (PrnAdmin) is a COM-based tool that provides large-scale, noninteractive control of printers, drivers, and ports on local and remote computers.
Using PrnAdmin, you can:
Add and delete a local or remote printer. Add and delete printer connections. Add and delete a local or remote form. Add and delete a local or remote standard TCP/IP port (of type Line Printer Remote (LPR) or RAW). Add and delete a local or remote driver. View a list of printers, ports, drivers, and forms on a local or remote computer. Control and configure a local or remote printer.
PrnAdmin consists of several scriptable COM objects residing in Prnadmin.dll, which functions as a wrapper around Printui.dll. Several Microsoft Visual Basic Script (VBScript) sample files are included with the tool.
Note
For more detailed information on how to use PrnAdmin.DLL, see Prnadmin.doc. This white paper provides additional information on printer, drivers, ports and forms to help administrators and programmers manage a large number of local and remote printers.
Corresponding Operating System Features
All the functionality of prnadmin.dll can be duplicated using the printers folder and various wizards. Converting printer ports from LPR to Standard TCP/IP is the only functionality in prnadmin.dll for which there is no corresponding GUI.
For more information about PrnAdmin and the Windows Management Instrumentation (WMI) scripts in Windows Server 2003, see Designing and Deploying Print Servers(http://go.microsoft.com/fwlink/?LinkIDG45) in the Windows Server 2003 Deployment Kit.
System Requirements
The following are the system requirements for this tool:
Windows 2000 or Windows Server 2003 operating systems.
Files Required
Prnadmin.dll Prnadmin.doc
The following sample VBScript files are also required:
Clean.vbs Clone.vbs (there is no WMI equivalent for the cloning script) Conall.vbs Defprn.vbs Drvmgr.vbs Forms.vbs Persist.vbs Portconv.vbs Portmgr.vbs Prncfg.vbs Prnctrl.vbs Prndata.vbs Prnmgr.vbs
Je teste et je vous dit ca
@+
-- torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway Administration scripting examples and an ONLINE version of the 1328 page Scripting Guide: http://www.microsoft.com/technet/scriptcenter/default.mspx
"technicland" a écrit dans le message de news:
vanzetti44 nous a dit :
je tente en vain de créer un script permettant la création d'une ("Win32_TCPIPPrinterPort").SpawnInstance_ mais il ne fonctionne qu'avec xp/2003. normal Win32_TCPIPPrinterPort
Requirements Client: Requires Windows XP. Server: Requires Windows Server 2003.
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetControlPrintPrinters.J'ai exporté le fichier reg et executer sur autre machine. apres un reboot, l'imprimante apparait. j'ai donc tenter de créer un batch avec regedit /s au demarrage de la machine, et la ce n'est pas pris en compte meme apres plusieurs reboot.Comment faire donc pour automatiser cette installation. Pour rendre l'imprimante disponible, je l'ai partagé sur le server et connecté apr script.merci beaucoup @ tousbonne journée.vanzetti44 ;)
Peut etre essayer avec un modele perso fichier .adm pour deployer les cles mais la technique d ajouter des clefs comme ca via le registre pour installer des choses, j ai pas trouve d autre methode via un xcript pour ajouter un port essaye sur le news scripting peut etre