Not with the DIR command, but the info is there to access. The time is
recorded in 100 million'ths of a second. Certainly there are a number of
interfaces available, and which one you use is probably most dependant on
what you are most comfortable with using. I would probably add a suffix to
the filename that showed the accurate time. The command: 'cscript list.vbs >
list.txt' would show you all attributes in 'c:\somefolder'.
--list.vbs--
Set objShell = CreateObject ("Shell.Application")
Set objFolder = objShell.Namespace ("C:\somefolder")
Set objFSO = CreateObject("Scripting.FileSystemObject")
Dim arrHeaders(13)
For i = 0 to 13
arrHeaders(i) = objFolder.GetDetailsOf (objFolder.Items, i)
Next
For Each strFileName in objFolder.Items
For i = 0 to 13
If i <> 9 then
Wscript.echo arrHeaders(i) _
& ": " & objFolder.GetDetailsOf (strFileName, i)
End If
Next
Wscript.Echo
Next
Thanks. I can get at it with code, and now I know I can stop wasting my
time fiddling with the DIR command.
The only reason I wanted to use the DIR command is that I have a program
which takes backups when the source file has a different size or
timestamp from the backup file, and I wanted a simple test that the
backup files matched the source files after it ran.
Then I found the bug in the backup program that was causing it to copy
the same (old) files over and over again.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.