khorton44
06-13-2002, 09:16 PM
I recently created the script below to map multiple printers but only the first printer on the list is being mapped. What am I missing here? Thanks in advance for help.
Set WshNetwork = CreateObject("WScript.Network")
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\2138rcps"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\hp_4050"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\Hp2100_A"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\Hp2100_B"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\Hp2100_C"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\hp 4100"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\tek 360"
Set WshNetwork = CreateObject("WScript.Network")
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\2138rcps"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\hp_4050"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\Hp2100_A"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\Hp2100_B"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\Hp2100_C"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\hp 4100"
WshNetwork.AddWindowsPrinterConnection "\\SitePrntSrv\tek 360"