This is a fairly old and ugly vbs script, and it only works for one OU in the domain, but it should get the job done.  You’ll need to modify strPathToContainer and strDomain.

 

Option Explicit

Dim strPathToContainer, strDomain

Dim oUser, oUserContainer

 

strPathToContainer = "OU=Student"

strDomain = ",DC=evangel,DC=edu"

 

Set oUserContainer = GetObject("LDAP://" & strPathToContainer & strDomain)

oUserContainer.Filter = Array("User")

 

For Each oUser In oUserContainer

            oUser.PutEx 1, "profilePath", vbNullString

            oUser.SetInfo()

Next

 

Set oUserContainer = nothing

 

MsgBox "Done"

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Harding, Devon
Sent: Monday, December 05, 2005 2:40 PM
To: ActiveDir@mail.activedir.org
Subject: [ActiveDir] remove logon script?

 

How can I remove the logon.bat from all my user (2000+) accounts at one time in my domain?  I’ve switch to GPO for the logon scripts.

 

Devon Harding

Windows Systems Engineer

Southern Wine & Spirits - BSG

954-602-2469

 


__________________________________
This message and any attachments are solely for the intended recipient
and may contain confidential or privileged information. If you are not
the intended recipient, any disclosure, copying, use or distribution of
the information included in the message and any attachments is
prohibited. If you have received this communication in error, please
notify us by reply e-mail and immediately and permanently delete this
message and any attachments. Thank You.

Reply via email to