
DeleteOldFiles is a command line utility that moves old files 
to the Windows 95/98/NT recycle bin.

Version 4.0.0

Changes since version 3.0.1
> Added flag -c (see below)
> Added flag -e (see below)
> Fixed problem with evaluation of file attributes.
  Previously, recursion did not work with directories 
  that had the archive bit on.
                                           

Distribution: Freeware

To use the program:
1) Copy DeleteOldFiles.exe to:
    a) your system directory (i.e. c:\WinNt\System32)
                    OR
    b) any directory in your path statement 
       (enter path from the command prompt to see current path)
                    OR
    c) a directory not in your path

2) Open a Windows Command Prompt window 
(Start/Programs/Command Prompt)

3) Enter 'DeleteOldFiles directory days [-r][-c][-n][-e]' 
          (if the program is not in a path directory use
           the fully qualified file name for example:
           'C:\Utilities\DeleteOldFiles directory days [-r]')
   where:
      'directory' is the directory where files will be deleted
      'days' is the age of the files to be deleted
      '-r' is an optional flag to include sub-directories in the search
      '-c' use the file's Creation date when calculating age,
	       default behavior is to use the Modify date.
      '-n' is an optional flag to disable file deletion - log file still produced
      '-e' deletes Empty directories using same criteria as for files

   Example:
      To delete files older than 45 days from the windows
      temp directory enter:
         DeleteOldFiles c:\Temp 45

      To delete files older than 45 days from the windows
      temp directory AND all of its sub-directories enter:
         DeleteOldFiles c:\Temp 45 -r

The program writes messages to a text file called:
   
   DeleteOldFiles.log

The log file is written to the directory that is current as of 
run time.  To view the log file enter 'Type DeleteOldFiles.log'


TECHNICAL DETAILS / NOTES
=========================

> System files and hidden files are NOT deleted

> In a network environment, files deleted from a network drive 
  (file server) do NOT get moved to the Recycle Bin - They are
  permanently deleted!

> The program was written in Visual Basic version 5 - source code is
  included in the zip file

> The program uses Windows Shell and system API calls to read and 
  remove files

> Due to a bug (???) with the Windows Shell Delete API function, files are NOT
  moved to the recycle bin if DeleteOldFiles is executed from the 
  Windows NT "at" scheduler.

> The program edits input arguments for validity

> -? can be used to get information about the program
  (DeleteOldFiles -?)

> Deleted files can be recovered from the Recycle Bin



Craig Duey
4/2000

cduey@CDWebTech.com






