Active Directory: Disable *another* users account

  • Thread starter Thread starter catherine
  • Start date Start date
C

catherine

Hi, I am trying to work out how I can disable / enable **another**
users Active Directory account not my own via C#.

If I create a directory entry like so I need to know the other users
password befoew I can do anything with the user. Obviously I will not
know this information

DirectoryEntry de = new DirectoryEntry();
de.Path = "LDAP://192.168.0.1/
CN=Users;DC=DEVELOPMENTDOMAIN";
de.Username = userName;
de.Password = password;

So, can someone please tell me how I can/ if it's possible to disable/
enable another users account via C#?

Thanks
Catherine
 
Back
Top