---INTRO------------------------------------
- 
The archive in which this text file is included should include
four programs dealing with batch files: WAIT, RAND, TIMEODAY, and
DAYSLEFT.  Following is a short description of each.

---WAIT-------------------------------------
- Batch file pauser

Usage:
   WAIT[.EXE] [delay]

Where:
   delay =  Number of milliseconds to pause.  Defaults to 1000.

Notes:
   1000 milliseconds = 1 second (Okay, okay, you know that...);
   therefore, WAIT 2000 would cause the program to pause for two
   seconds.

---RAND-------------------------------------
- Generates random numbers

Usage:
   RAND[.EXE] [min] [max]

Where:
   min   = Lower limit of generated number  (Default: 0)
   max   = Upper limit of generated number  (Default: 9)

Notes:
   Use this program with the ERRORLEVEL function to use
   random numbers in batch files.  For example, the fol-
   lowing code would cause the batch program to branch
   randomly to one of three locations:

   ----8<---Cut here----------
   @echo off

   RAND 1 3
   if errorlevel 3 goto ChoiceOne
   if errorlevel 2 goto ChoiceTwo
   if errorlevel 1 goto ChoiceThree
   goto EndOfFile

   :ChoiceOne
   echo One
   goto EndOfFile
   
   :ChoiceTwo
   echo Two
   goto EndOfFile

   :ChoiceThree
   echo Three
   goto EndOfFile

   :EndOfFile
   echo The End
   ----8<---Cut here----------

---TIMEODAY---------------------------------
- Returns the time of day

Usage:
   TIMEODAY[.EXE]

Notes:
   * The program returns one of four values:
      "1" for "Morning";
      "2" for "Afternoon";
      "3" for "Evening";
      "0" for "ERROR".
   * Advice:  If it ever happens that it is neither morning,
      afternoon, nor evening, it may be a good idea to start
      praying and listen for the sound of trumpets... :)

---DAYSLEFT---------------------------------
- Gives the approximate number of days until the specified date

  Usage:
      DAYSLEFT [mm dd yy{yy}] [/Fx] [/T]

   Where:
      mm      Represents the month for which to calculate.
      dd      Represents the day.
      yy{yy}  Represents the 2- or 4-digit year.
      /Fx     Changes the format of the output date. (x) is
               a number from 0 to 3 naming the format.  The formats are:
               0. Normal, 1. Year first  2. English, and 3. English with
               the day first.  Defaults to 2.
      /T      Terse.  Prints only necessary info.

   Note:
      The internal clock is used to find today's date.


---EOF--------------------------------------
- 
Hope these programs are useful to you (and even though it looks as
though DOS is forever dead, hopefully M*crosoft will leave the sweet
functionality of batch files in later permutations of Windows).
Questions, comments, monetary donations, etc. should be directed
to bjslone@netscape.net or sent via snail mail to:
             
             Brett J. Slone
             PO Box 27
             Garner, KY  41817


Copyright (C)1996 Brett J. Slone.
Programs are freely distributable when accompanied by this text file.
