roy roy

roy roy

  • NA
  • 27
  • 0

connecting to Active Directory

Apr 10 2007 9:26 PM
Hello.
Your help is very much appreciated.
I am trying to get the groups a specific user belongs to from Active Directory.
Iv'e see many examples of how to do it.
But, I don't understand one basic thing...
How to tell Active Directory, which user I want to get the groups for????

in the examples I see connections string like:

"LDAP://DC=Microsoft,DC=COM" "name" "Microsoft"

What is DC??????

My connection string:

DirectoryEntry x = new DirectoryEntry(LDAP://myservername,"username","password",System.DirectoryServices.AuthenticationTypes.ServerBind);

will get me connected to Active directory.
but how do I specify which user I want to enquire????
the user name and password used in the code above are for connecting to active directory...

Thanks
Roy

Answers (1)