Hmw2txt - version 0.1, 11/14/2004
---------------------------------

This program converts files created by Sierra Homeword for DeskMate to 
plain ASCII text.  To run the program, specify the file to convert, and 
optionally the output filename, on the command line:

    HMW2TXT INPUT.HMW

or

    HMW2TXT INPUT.HMW OUTPUT.TXT

If you don't specify the output file, the output filename is generated by 
replacing the extension on the input filename with ".TXT".  Either or both 
filenames can contain drive and/or path.

ERROR MESSAGES -----------------------------------------------------------

Normally no message will be displayed if the program works correctly.  If 
something goes wrong, you will get one of the following messages:

    Hmw2txt, Homeword for DeskMate to text converter.  Syntax:

       hmw2txt <infile> <outfile>

    where <infile> is input Homeword file, <outfile> is output
    text file.  <infile> is required, <outfile> will be generated
    from <infile> if not specified. [1]

You get that message if you don't specify a filename to convert.

    Input and output files are the same. [17]

You specified the same file for both input and output, or the generated 
output filename ended up the same as the input name.  Explicitly specify a 
different name for the output file.

    Failed to open input file. [2]

The input file was not found.  Check your typing.

    Failed to open output file. [3]

The output file could not be created.  Make sure your disk isn't write- 
protected or read-only (like a CDROM).  Make sure there isn't already a 
read-only file with the same name.

    Premature EOF on input file. [4]

The input file is too short to be a Homeword file (it doesn't have a 
Homeword header).

    Input file is not a Homeword for DeskMate file. [5]

The input file is not a Homeword for DeskMate file (it doesn't have a 
Homeword header).  This program doesn't deal with Homeword for DOS files.

    Input file contains no text. [6]

The input file is a Homeword file, but it is truncated and has no text to 
convert.

    Failed to generated temporary filename. [7]

Hmw2txt uses a temporary file to hold text between passes.  It was unable 
to create a filename that was not already in use.  About the only way this 
can happen is if Hmw2txt runs several times but locks up before it 
finishes, which of course should never happen.  If you are having that much 
trouble but you still want to try again, go to your temp directory (the one 
pointed to by the TMP environment variable) and delete all files named 
HMW2TXT*.  If your TMP variable is not set, the root directory of the 
current drive is used, so look for leftover temp files there.

    Failed to create temporary file. [8]

Hmw2txt uses a temporary file to hold text between passes.  It was unable 
to create this file, probably because the directory where the file was to 
be stored was not writeable.  To fix this problem, set the TMP environment 
variable to point to a writeable directory, by typing this at the DOS 
prompt:  SET TMP=C:\TEMP (substitute whatever directory you want to use - 
you also need to create the directory if it doesn't already exist).

    Error writing to temporary file. [9]

The program failed to write data to the temporary file, probably because 
the drive is full.  Delete some files to make more space.  The temporary 
file will either be stored in the directory pointed to by the TMP 
environment variable, or in the root directory of the current drive.

    Error reading from input file. [10]

If you see this, it probably means your diskette is bad, or you removed it 
before Hmw2txt was done reading from it.  It could also mean that this 
program didn't understand your input file (see error [11] below).

    Unexpected data in Homeword file. [11]

This program encountered something strange in the input file.  Make sure 
the file hasn't been corrupted.  If it is a good file, I would have to make 
changes to Hmw2txt to let it be converted.  Email me the file and I will 
see what I can do (see below for the email address).  The source code is 
also included if you want to make changes yourself (see below).

    Error closing temporary file. [12]

This is the same as error writing to temporary file (see error [9] above).  
Your disk is probably full.

    Error opening temporary file for reading. [13]

This should never happen, unless you are using diskettes and pulled the 
disk out at just the right time.

    Error reading from temporary file. [14]

You only get this if the temporary file has already been created 
successfully, so either you removed the diskette it was on or the media it 
is on is going bad.  Set the TMP environment variable to a different 
directory.

    Error writing to output file. [15]

The disk the output file is on is probably full.  Delete some files.

    Error closing output file. [16]

Same as the above (error [15]).

BATCH FILES --------------------------------------------------------------

If nothing goes wrong, Hmw2txt will return ERRORLEVEL 0.  Otherwise, the 
errorlevels correspond to the numbers of the error messages above.  If you 
don't care what the error is, "IF ERRORLEVEL 1" will cover it.

SOURCE CODE --------------------------------------------------------------

The source code (C) is attached.  If you change it so the program works 
better, please email me the new version so I can put it on my WWW/FTP site.

AUTHOR -------------------------------------------------------------------

The author can be reached at:

    tvdog@sbcglobal.net
    http://tvdog.shacknet.nu
    ftp://tvdog.shacknet.nu

The last version of Hmw2txt will be in the tandy1000/deskmate directory on 
the above site.
