Deploying a printer from pdq deploy
Hello.
I have had a script for deploying printer to machines from pdq. i have posted this before, maybe noone noticed.
you need the (IP) (driver in repository) (name of .inf) (printer model) (printer name)
for windows XP and 7.
here are examples of both scripts.
they can be changed for any printer.
===================================================================================
XP BATCH: FOR A LASERJET CP1510
MKDIR C:\CP1510
XCOPY \\SERVER\SHARE\DRIVERS\PRINTERS\HP\LASER\cp1510\*.* C:\CP1510 /E /Y
Cscript C:\windows\system32\Prnport.vbs -a -r IP_*.*.*.* -h *.*.*.* -o raw -n 9100
rundll32 printui.dll,PrintUIEntry /ia /f C:\CP1510\hppcps09.inf /m "HP Color LaserJet CP1510 Series PS"
rundll32 printui.dll PrintUIEntry /if /f C:\CP1510\hppcps09.inf /b "HP Color LaserJet CP1510 Series PS-WORKROOM" /m "HP Color LaserJet CP1510 Series PS" /u /r "IP_*.*.*.*"
MSG * /TIME:1000 "THIS COMPUTER CAN NOW PRINT TO WORKROOM. -IT."
==============================================================================
WINDOWS 7:FOR A HP LASERJET PRO 400
MKDIR C:\PRO400
XCOPY \\SERVER\SHARE\DRIVERS\PRINTERS\HP\LASER\PRO400\*.* C:\PRO400 /e /y
xcopy \\SERVER\SHARE\VBS\print\*.* c:\windows\system32 /e /y
Cscript C:\windows\system32\Prnport.vbs -a -r IP_*.*.*.* -h *.*.*.* -o raw -n 9100
rundll32 printui.dll PrintUIEntry /if /f C:\PRO400\hpbuio20l.inf /b "HP LASERJET PRO 400-front office" /m "HP LJ300-400 COLOR MFP M375-M475 PCL 6" /u /r "IP_*.*.*.*"
MSG * /TIME:1000 "THIS COMPUTER CAN NOW PRINT TO FRONT OFFICE. -IT."
=============================================================================
for windows 7 you must have the vbs scripts in your repository and copy them to system32.
these vbs are not found in windows 7.
copy them from any xp
they are:
prndrvr.vbs
prnmngr.vbs
prnport.vbs
==========================================================
hope you like them.
thank you.
-TREVINO
Comments
I know this is an older article but I was wondering if anyone could maybe give me a hand.
The following is what I am using. It is not exact just without our file names and IP's.
MKDIR C:\HP400M401
XCOPY "\\serverinformationhere1\hpcm401c.inf" C:\HP400M401 /e /y
Cscript "C:\Windows\System32\Printing_Admin_Scripts\en-US\Prnport.vbs" -a -r IP_*.*.*.* -h *.*.*.* -o raw -n 9100
rundll32 printui.dll PrintUIEntry /if /f C:\HP400M401\hpcm401c.inf /b "TSC2" /m "HP LaserJet 400 M401 PCL 6" /u /r "IP_*.*.*.* "
MSG * /TIME:1000 "THIS COMPUTER CAN NOW PRINT TO TSC2. -IT."
This works fine on one machine and will not on any other.
Getting operation could not be completed (error 0x800f0214)
you need the whole driver folder...
so
XCOPY \\serverinformationhere1\driver\*.* C:\HP400M401 /e /y