Adding Network Printers using a "Startup" script.

D

Dragonfly

I have created the following policy to be run at the OU
level on:
Computer Configuration, Windows Settings, Scripts, Startup.

'VBScript Test to add Printers

Set WshNetwork = CreateObject("WScript.Network")
WshNetwork.AddWindowsPrinterConnection "\\Server01
\ITLaserJet4100N"
Set WshNetwork = CreateObject("WScript.Network")
WshNetwork.AddWindowsPrinterConnection "\\Server01
\ITColourPrinter"
Set WshNetwork = CreateObject("WScript.Network")
WshNetwork.AddWindowsPrinterConnection "\\Server01
\Accounts Printer"

However, the printers are not been added
during "startup". If I double click on the script, the
printers will be added.

In the security settings for this policy, I have the
following ticked:

Authenticated Users: Read, Write
Creator Owner: Blank
Domain Admins: Read, Write, Create All Child Objects,
Delete All Child Objects
Enterprise Admin: As for Domain Admins
System: As for Domain Admins.

Do I need to add any more groups to this Security Group?
At the moment, no-one has the "Apply Group Policy" ticked.

Any help will be greatly appreciated.

Thanking you in advance.
 
M

Matjaz Ladava [MVP]

Why are you running this on computer startup ? Do this on a Users Setting as
logon script and assign this policy to users OU. It is better this way. Make
sure, that users have Read + Apply policy right on the GPO.

--
Regards

Matjaz Ladava, MCSE (NT4 & 2000), Windows MVP
(e-mail address removed)
http://ladava.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top