c# - Active Directory Is User Deactivated Code Snippet Needed? -
Can anyone post a way to know if a particular user is a passive user in Windows Advertising?
If you are on .NET 3.5 or upgrade to .NET 3.5 - New Take a look at the system. Directory Services Look for an introduction to account management [/ code> namespace which makes many air from these tasks.
In your case, you can write your code like this:
Principal Consultation CTX = New Principal Contex (ContaxType Daemon, "uradann") UserPinional User = User Principal Foundbyintenti ("anonymous"); Bool locked = user.IsAccountLockedOut ();
All this is there! Most of the daily employment of users and groups has improved significantly with NET 3.5 - use those new capabilities!
Comments
Post a Comment