Solved

Dos command to include when files were access date? (not modified) something added to this?   tree /f /a >tree.txt

Posted on 2011-03-11
8
569 Views
Last Modified: 2012-05-11

Hi,

I need to know when files were last accessed - the date.

So say a word doc:

I make a file on a monday - creation date.
I open / edit save it on tuesday - modify date.
I open close it on wed - last access date.

Is there a way to find this out?

I need to do this for a load of files.
Its a dispute between two people and one party needs to know access date of her files.

Thanks.




0
Comment
Question by:fcek
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 9

Expert Comment

by:x3man
ID: 35108312
You might be able to do this with Powershell, see: http://www.experts-exchange.com/OS/Microsoft_Operating_Systems/Q_26875294.html
0
 
LVL 3

Expert Comment

by:OrenRozen
ID: 35108463
0
 
LVL 96

Expert Comment

by:Lee W, MVP
ID: 35111474
DIR /TA

And reference the DIR command built-in help:
C:\Temp>dir /?
Displays a list of files and subdirectories in a directory.

DIR [drive:][path][filename] [/A[[:]attributes]] [/B] [/C] [/D] [/L] [/N]
  [/O[[:]sortorder]] [/P] [/Q] [/R] [/S] [/T[[:]timefield]] [/W] [/X] [/4]

  [drive:][path][filename]
              Specifies drive, directory, and/or files to list.

  /A          Displays files with specified attributes.
  attributes   D  Directories                R  Read-only files
               H  Hidden files               A  Files ready for archiving
               S  System files               I  Not content indexed files
               L  Reparse Points             -  Prefix meaning not
  /B          Uses bare format (no heading information or summary).
  /C          Display the thousand separator in file sizes.  This is the
              default.  Use /-C to disable display of separator.
  /D          Same as wide but files are list sorted by column.
  /L          Uses lowercase.
  /N          New long list format where filenames are on the far right.
  /O          List by files in sorted order.
  sortorder    N  By name (alphabetic)       S  By size (smallest first)
               E  By extension (alphabetic)  D  By date/time (oldest first)
               G  Group directories first    -  Prefix to reverse order
  /P          Pauses after each screenful of information.
  /Q          Display the owner of the file.
  /R          Display alternate data streams of the file.
  /S          Displays files in specified directory and all subdirectories.
  /T          Controls which time field displayed or used for sorting
  timefield   C  Creation
              A  Last Access
              W  Last Written
  /W          Uses wide list format.
  /X          This displays the short names generated for non-8dot3 file
              names.  The format is that of /N with the short name inserted
              before the long name. If no short name is present, blanks are
              displayed in its place.
  /4          Displays four-digit years

Switches may be preset in the DIRCMD environment variable.  Override
preset switches by prefixing any switch with - (hyphen)--for example, /-W.

Open in new window

0
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

 
LVL 63

Expert Comment

by:btan
ID: 35114545
dir "<Path to target directory>"/T:C /T:W /S /Q >> "<path to dest output file>"
- for timestamp, it shows file creation (/T:C) , last written (/T:W). if you want, can add "/T:A" for last access

Reference - http://en.kioskea.net/forum/affich-162585-get-filenames-timestamps-batch-file

0
 
LVL 15

Accepted Solution

by:
Russell_Venable earned 500 total points
ID: 35131276
I would just use DIR /TA /OD /S > Dir.txt

Recurses from the current folder you called it and all subfolders and sorts the oldest files first then lists the accessed times on the left side of the columns and then the listed file on the right column.
0
 
LVL 15

Expert Comment

by:Russell_Venable
ID: 35137257
Any news?
0
 

Author Comment

by:fcek
ID: 35138857

This worked.

Russell_Venable:I would just use DIR /TA /OD /S > Dir.txt


0
 
LVL 15

Expert Comment

by:Russell_Venable
ID: 35142085
Great! Glad it worked for you. It worked for me too! :)
0

Featured Post

Enroll in May's Course of the Month

May’s Course of the Month is now available! Experts Exchange’s Premium Members and Team Accounts have access to a complimentary course each month as part of their membership—an extra way to increase training and boost professional development.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The foremost challenge encountered by an investigator at the very beginning of a forensics investigation is, accessing a file/data to read/view its contents. Owing to the fact, a platform is necessary for both; opening as well as examining any file.…
In this era, as you know, cybercrime and other sorts of frauds using the internet has increased day by day. We should protect our information assets and confidential information from getting exploiting by the attacker or intruders. Most of the fraud…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

740 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question