Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Running VB Scripts 1

Status
Not open for further replies.

Skittle

ISP
Sep 10, 2002
1,528
US
If I needed to execute a vbscript against a set of users in an AD domain once, what is the recommended method?

Should I just modify the Login script to conditionally run it once? Is there another way other than relying on a user to run it from email or an intranet site?

Dazed and confused
 
my suggestions:

either

1) create a group with the single purpose to run the script. Add the users to the group. Give the users rights to *remove themselves* from the group. At the end of the script, include code to remove the user.

2) run sysinternals' psexec to execute the script remotely, against all the users...
 
I think how you handle this would be determined by what the script is doing. For example, if the script is modifying the computer the user uses, then I would use a registry key to determine that the script has already run and if so quit execution. That way you can leave the script in place and if a user get a new PC, the same changes will be applied.

I also like bluray's first suggestion. But not knowing what you need to actually script it is hard to make a recommendation.

I hope you find this post helpful.

Regards,

Mark

Check out my scripting solutions at
Work SMARTER not HARDER. The Spider's Parlor's Admin Script Pack is a collection of Administrative scripts designed to make IT Administration easier! Save time, get more work done, get the Admin Script Pack.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top