facebook  linkedin  Twitter  skype  Rss googlePlus

ADSI: Get Group Membership for Account

Oct 12 2004

The following code will use ADSI to obtain all the groups assigned for a specific user account:

Dim strDomain = “mydomain“
Dim strUser = “someuser“
Function GetMemberGroups()
 Dim oUser = GetObject(strDomain & "/" & strUser)
 Dim strTemp
 For Each oGroup In oUser.Groups
  strTemp = strTemp & oGroup.Name & "
 GetMemberGroups = strTemp
End Function

About the Author, Patrick Santry

Patrick Santry, has two decades of experience in enabling businesses to take advantage of the digital landscape. A well rounded experience in technology, and business is what sets me apart from the rest of the pack. When it comes to an overall digital strategy my experience is impressive.

BS in Computer Information Systems. Four time recipient of the Microsoft MVP Award, and author of several books and magazine articles on digital technologies.

blog comments powered by Disqus


Thank you for visiting our site, before you leave, please visit some of the areas or information you may have missed.

Popular Articles