Skip to content

Instantly share code, notes, and snippets.

@aahan
Created July 16, 2014 19:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aahan/b7be81e47092bf9faf63 to your computer and use it in GitHub Desktop.
Save aahan/b7be81e47092bf9faf63 to your computer and use it in GitHub Desktop.
Windows 7 File Properties: Get 'date created' up to seconds using PowerShell

Open PowerShell: Start > All Programs > Accessories > Windows PowerShell > Windows PowerShell

To get Date Created, run commands:

$file = Get-Item "D:\My folder\my-file.md"
$file.CreationTime

The output will look like this (in system's local time):

Wednesday, July 16, 2014 16:24:00

Use $file.LastAccessTime and $file.LastWriteTime to get Last Accessed and Last Modified times respectively.

Sources:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment