Move Next Wend This script finds all members of a group in the entire forest in which the current user (which the script is running) is a member. Execute(";" & ldap Filter & _ ";distinguished Name,primary Group Token;subtree") group DN = object List.The group itself has to be in the same domain as the user who runs this script. Fields("distinguished Name") group RID = object List.By access here I mean a network connection - you don't need to be able to logon to a DC to get this information - as you just use the directory search tool mentioned above.You should still be able to use Active Directory Users and Computers to see group memberships, assuming your PC is a member of the domain and you are logged in with a domain account.By default, for new users the primary group property is set to 'domain users', so it is often not important that this group membership is missing in the basic evaluation of the values.However, if other groups are registered as a primary group, this traditional way of membership evaluation is not accurate enough!Filter = "(&(object Category=group)(cn=))" ' search filter; only display emp with firstname / lastname pair osearcher. Data Bind() End Sub Dim Users In Group As New Collection() Dim de As New Directory Entry("LDAP://[Domain]") Dim Member Searcher As New Directory Searcher With Member Searcher . Filter = "(&(Object Class=Group)(CN=" & Group & "))" . Add("Member") End With Dim my Search Results As Search Result = Member Searcher.



The group name is Over Riders and 8 people are members of this group. I have the following dropdown but I run the code, the dropdown is blank. Please see code: Private Sub Fill Dropdown() Dim oroot As Directory Entry = New Directory Entry("LDAP://CN=Over Riders, OU=Departments, DC=domain, DC=com") Dim osearcher As Directory Searcher = New Directory Searcher(oroot) Dim oresult As Search Result Collection Dim result As Search Result Dim list As New List(Of String) osearcher. Find All() For Each result In oresult If Not result. Fields("sam Account Name") On Error Resume Next display Name = "" : display Name = object List.Fields("displayname") logon Name UPN = "" : logon Name UPN = object List.You just won't be able to modify said group memberships.If not, then the domain admins have set security such that you're restricted from viewing the memberships in which case you won't be able to see memberships.