Disables a user account.
Const ADS_UF_ACCOUNTDISABLE = 2Set objUser = GetObject _("LDAP://cn=myerken,ou=management,dc=fabrikam,dc=com")intUAC = objUser.Get("userAccountControl")objUser.Put "userAccountControl", intUAC OR ADS_UF_ACCOUNTDISABLEobjUser.SetInfo
This is a VB Script, this can be used by saving the file in .vbs file