home *** CD-ROM | disk | FTP | other *** search
- @echo off
-
- :: To use this batch file, type the INPUT file name as the first
- :: parameter, and next the name of the OUTPUT file. Note
- :: that the batch file supplies the "-W" parameter automatically. If
- :: you are using the UNregistered version of WordSmart, the "-Q"
- :: switch used in the command line below will not have any effect.
- :: (See the documentation for more information about the WordSmart
- :: commands that are supported in the registered version.)
-
- if "%1" == "" goto NOPARM
-
- WSM %1 -w %2 -q %3 %4 %5 %6 %7 %8 %9
-
- echo.
-
- if errorlevel 5 goto read_only
- if errorlevel 4 goto targeterr
- if errorlevel 3 goto exist
- if errorlevel 2 goto cantoverwrite
- if errorlevel 1 goto readerr
-
- echo.
- echo ---------- WordSmart: Processing was successful ----------
- goto end
- :read_only
- echo.
- echo ---------- WordSmart: The output file (%2) is Read only! ----------
- goto end
- :targeterr
- echo.
- echo ---------- WordSmart: Can't write the output file (%2)! ----------
- goto end
-
- :cantoverwrite
- echo.
- echo ---------- WordSmart: Cannot overwrite itself! ----------
- goto end
-
- :exist
- echo.
- echo ---------- WordSmart: Output file exists! (use '-O' to over-write) ----------
- goto end
-
- :readerr
- echo.
- echo ---------- WordSmart: Can't find specified input file (%1)! ----------
- goto end
-
- :noparm
- echo.
- echo This batch file requires some parameters on the command line.
- echo Read the text at the start of the batch file itself for
- echo more information.
- echo.
- pause
- cls
- WSM
-
- :end
-