DirectoryEntry rootEntry = neues DirectoryEntry („LDAP: ///dc=DOMAIN, dc=COM“);
DirectorySearcher dsFindOUs = neues DirectorySearcher (rootEntry);
dsFindOUs.Filter = „(objectClass=organizationalUnit)“;
dsFindOUs.SearchScope = SearchScope.Subtree;
foreach (SearchResult Resultat in dsFindOUs.FindAll ())
{
Console.WriteLine (Resultat. Weg);
}
|