WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

ADSI
plus

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

AD Account Creation Date


Question:

Does anyone have experience or thought on how to determine when an AD account was created? Thank in advance!

Answer:

Most AD objects have the "Createtimestamp" property. It holds the time an object was created (as the name implies) in GeneralizedTime format.

From MSFT documetation: "The format for the GeneralizedTime syntax is "YYYYMMDDHHMMSS.0Z". An example of an acceptable value is "20010928060000.0Z". The "Z" indicates no time differential. Active Directory stores date/time as Greenwich Mean Time (GMT). If no time differential is specified, GMT is the default.

If the time is specified in a time zone other than GMT, the differential between the time zone and GMT is appended to the string instead of "Z" in the form "YYYYMMDDHHMMSS.0[+/-]HHMM". An example of an acceptable value is "20010928060000.0+0200"."

You can use the ADSI extender or Winbatch's OLE functions to get property's value. In extender syntax it would be as follows:

createdate=dsGetProperty(sUsePath, "Createtimestamp")

Article ID:   W15799
File Created: 2004:03:30:15:40:56
Last Updated: 2004:03:30:15:40:56