Active Directoy LDAP - Lock User Account
Posted
by Germ
on Stack Overflow
See other posts from Stack Overflow
or by Germ
Published on 2010-05-04T19:29:28Z
Indexed on
2010/05/04
19:58 UTC
Read the original article
Hit count: 238
What is the prefered way to lock an Active Directory account?
int val = (int)directoryentry.Properties["userAccountControl"].Value;
directoryentry.Properties["userAccountControl"].Value = val | 0x0010;
vs.
directoryentry.InvokeSet("IsAccountLocked", true);
Is there a better way?
© Stack Overflow or respective owner