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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Determining AD Group Membership in vbs

Status
Not open for further replies.

dmanlam

IS-IT--Management
Apr 17, 2002
33
GB
I've searched in here, but I cannot seem to locate any definitive explanation of how to "check" a person's group membership (AD) from within a simple vbs script. I know it's possible and Technet comes close to it, but still no luck (they tell you how to "ADD" an account to an AD group thru vbs). I don't want to add, delete, modify...I just want to check, like:
if user1 is in ADGroup1 then
run some code
else
run some other code
endif

I know you set a reference using "GetObject" along with some kind of LDAP syntax. From there, however, I couldn't determine the specific "method" to use on the referenced object (.Add, .Delete, etc -- don't want these, though).

ANY help is HUGELY appreciated (to others as well ;-) )
Thanks,
Drew
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top