troubleshooting Question

Query Active Directory for Date an account is Disabled

Avatar of kendingo
kendingoFlag for United States of America asked on
Windows 2000Active Directory
3 Comments1 Solution15462 ViewsLast Modified:
Hello Experts,

I am trying to find out a way to query AD using the ADU&C interface in a way that will show me the disabled accounts that were disabled before a specific date.
Basically i need to know what the field or userAccountControl code is, if there is one at all.

I curentlly have a saved query to gather all my disabled users which looks like this:
   (&(objectCategory=person)(objectClass=user)(userAccountControl:1.2.840.113556.1.4.803:=2))

I also played around with a query that would give me all my disabled users created before a specific date which looks like this:
   (&(&(objectCategory=person)(objectClass=user)(userAccountControl:1.2.840.113556.1.4.803:=2)
   (whenCreated>=20050801000000.0Z)))
   This query does not quite meet my needs but gets me closer to the end goal.

Any help would be great.
Dingo
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 3 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros