list files by date

J

Jim

Hello,
I am trying to list file names in a folder and sub folders
starting from a modified date that I will give to today in
the command line in windows 2000. How can I do that?
Thanks,
cT.
 
R

Ritchie

Jim said:
I am trying to list file names in a folder and sub folders
starting from a modified date that I will give to today in
the command line in windows 2000. How can I do that?

Do you mean list all files in a folder and sub-folders
that have been modified today?
 
M

Michael Bednarek

Hello,
I am trying to list file names in a folder and sub folders
starting from a modified date that I will give to today in
the command line in windows 2000. How can I do that?

One convenient way of doing this is to use a command line interpreter
which knows about date ranges. 4NT from JPSoft does. This is how I list
file which have been modified today: "DIR /[d-0]". To list files which
have been modified since Sep. 12, 2003, one would use:
DIR /[d2003-09-12] (regardless of locale settings).

4NT's date ranges are documented at
<http://jpsoft.com/help/dateranges.htm>

Other command processors might require more elaborate methods.
 
P

Phil Robyn

Jim said:
Yes. If possible, I want to give range like from two days
ago up to now.

If you download FORFILES.EXE (free) from Microsoft, you can
do something like the following example, which lists all of
the *.cmd files in directory c:\cmd\demo that are 35 days old
or newer:

- - - - - - - - - - begin screen capture - - - - - - - - - -
<Win2000> c:\cmd>forfiles -pc:\cmd\demo -m*.cmd -d+35 -c"cmd /c echo @FDATE @FILE"
20030822 DeleteProfiles.cmd
20030824 dumpvars.cmd
20030831 ShowFolderSpace.cmd
20030828 OldCreateDirStructure.cmd
20030829 month.cmd
20030830 ReadAndEcho.cmd
20030917 ExtractIPAddresses.cmd
20030922 FixMySpreadsheet.cmd
20030924 ValidDrives.cmd
- - - - - - - - - - end screen capture - - - - - - - - - -

You can download FORFILES.EXE from ftp://ftp.microsoft.com/reskit/y2kfix/x86/
 

Ask a Question

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.

Ask a Question

Top