Is it possible to view the last time a file was modified in Windows command prompt in milliseconds or even in seconds?
-
Do you really mean DOS, or do you mean via a command prompt or batch file in Windows? – Vicky Feb 27 '13 at 13:26
There is no native Windows command line utility that supports viewing time stamps with a resolution of milliseconds.
Your best option would to either use a 3rd party tool or for a native solution (Vista+), use robocopy
(supports seconds):
robocopy /L /TS . ..
Tracking a resolution finer than seconds might be trivial or useless as well depending on the file system being used. See http://msdn.microsoft.com/en-us/library/windows/desktop/ms724290(v=vs.85).aspx and http://jpsoft.com/help/index.htm?timestamps.htm
FAT has a write time resolution of 2 seconds.
-
The
robocopy /L /TS . ..
command works with files to show the timestamp to the second, but it doesn't work with folders/directories :(. Update, thanks to stackoverflow.com/users/479574/mark:forfiles /c "cmd /c echo @path @fdate @ftime"
. – Rublacava 6 mins ago
The robocopy
answer does work, but another nice option that works from the standard Windows console (not DOS per se):
forfiles /c "cmd /c echo @file @ftime"