المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : AD group



C# Programming
11-14-2009, 07:51 PM
i am running the method to get all my users in a group

my only problem is it only get the first 1000 users i have 2500 users in this group how do i change the capacity to 3000

public static ArrayList getUsers()
{
ArrayList excludeGroups = new ArrayList();
ArrayList users = new ArrayList();
excludeGroups.Add("CN=GMDPortal,OU=IT,OU=ADM,DC=corp,DC=ad,DC=ejhospital,DC=com");

foreach (string DEgroup in excludeGroups)
{
DirectoryEntry group = new DirectoryEntry("LDAP://" + DEgroup);

foreach (object dn in group.Properties["member"])
{
users.Add(dn);
}
}
return users;
}