Hi all,
I've one user, let's say "user_one" who is granted to access to a terminal
server "ts01", on this terminal server is installed for that user a printer
(shared on a third machine):
user_one is the user who logons
ts01 is the terminal server (Windows 2008)
pc01 is the pc on wich is shared the printer
hp101 is the printer name
I'm searching for a script that set \\pc01\hp101 as the default printer for
user_one, I'me trying the following:
Set WshNetwork = WScript.CreateObject("WScript.Network")
PrinterPath = "\\pc01\hp101"
WshNetwork.AddWindowsPrinterConnection PrinterPath
WshNetwork.SetDefaultPrinter PrinterPath
WScript.Quit
but the script does nothing
|