Contents of the WHEN.DOC file
W H E N
I have modified these files and this documentation to be more clear.
The original WHEN documentation is shown at the end of this file.
WHEN is a public domain program that checks for a properly operating
battery driven clock in the IBM PC. It always returns the date and time
(whether or not they are correct), but it also sets the errorlevel flag to 1 if
it finds a clock error. You would usually call WHEN from your AUTOEXEC.BAT file
| (blah, blah--batch file stuff)
if not errorlevel 1 goto :dateok
echo The battery-driven clock is not working.
echo Set The correct date:
echo Now set the correct time:
| (blah, blah--more batch file stuff)
The files you should have are:
WHEN.COM (the program)
WHEN.ASM (the source code)
WHEN.DOC (this file)
Here is the original documentation:
Time and Date Display & Check
This setup is used when you have a battery backedup clock.
You don't want to have to press return at the DOS time and
date prompts. (Besides, you probably already are using a
batch file.) Still, it is comforting to see the time and
date displayed when your system starts up.
Besides, eventually that battery is going to have run down.
If you are used to starting up without checking your time
and date, you may run a long time without noticing that your
files are all timestamped wrong.
Incorporate this AUTOEXEC.BAT file in your startup and rest
assured that you will be informed when the clock is dead. I
use an AST MegaPlus board and a CLOCK.SYS driver to go with
it. Any other way of initializing the DOS clock will work,
but the clock driver suites me best.
Stephen L. Billard