Searching Active Directory
Im new to c# asp programing and would like some help with the following.
Iâm trying to search active directory for a specific users âschenkpâ for this case and have results outputting to a list box. Say the user is schenkp I would like to know what groups he is a member of that have the specific word âownerâ.
I have a web page that consist of a button, list box and a text box. This code works and returns all the member of the active directory so far when I click the button.
private void Button1_Click(object sender, System.EventArgs e)
DirectoryEntry de = new DirectoryEntry("LDAP://GCM.COM/ou=user accounts,ou=accounts,dc=gcm,dc=com","schenkp","mat terhorn");
foreach(DirectoryEntry child in de.Children)
Any help would be greatly appreciated,