home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Media Share 9
/
MEDIASHARE_09.ISO
/
batch
/
askcom2d.zip
/
ASK.DOC
< prev
next >
Wrap
Text File
|
1992-08-08
|
4KB
|
106 lines
6 August 1992
PaceSoft Utilities
Ask.Com Version 2d
Ask.Com is a batch-file enhancement utility for MS/PC DOS systems.
Using the batch commands (language) provided in DOS, you can do most
anything but get user input "into" the batch file. Ask.com provides the
means for obtaining User input for use in a batch file.
Ask.Com is very useful for creating Menu batch files, and for providing
multiple options in response to other programs which have multiple return
codes for differing conditions... For creating Menu systems, it is one of
the best procedures to use as it doesn't tie up memory "spawning" the
requested program, as most menu shell type programs do. It is also easy to
learn the DOS Batch commands as well as the "extentions" Ask provides, thus
the menu system is easily configured to meet changing use of the system.
For example, suppose you desire to have a batch file that will format a
diskette, you could write a separate batch file for each type of diskette
the machine is capable of formatting... or you could "Ask" the user what
he/she desires, and act upon the users input to make a decision on how to
format the diskette using Ask.Com. As an example:
@Echo Off
:format
Echo.
Echo 1> Format 3-1/2" Diskette in drive A
2> Format 5-1/4" Diskette in drive B
3> OOPS! let me outta here!
Ask n
if errorlevel 4 goto oops!
if errorlevel 3 goto end
if errorlevel 2 goto drivb
if errorlevel 1 goto driva
if errorlevel 0 goto oops!
:oops!
Echo Invalid Choice!
goto format
:drivb
Echo Do you want to format it at 1.2 Meg?
ask A
if errorlevel 2 goto end
if errorlevel 1 goto hib
if errorlevel 0 goto lob
:hib
format b:
goto end
:lob
format b: /f:360
goto end
:driva
Echo Do you want to format it at 720K?
Ask A
if errorlevel 2 goto end
if errorlevel 1 goto loa
if errorlevel 0 goto hia
:hia
format A:
goto end
:loa
format A: /f:720
goto end
:end
Ask.Com operates in one of two modes. Alpha-mode will prompt for a Yes,
No, or Abort and return 0 for no, 1 for yes, and 3 for Abort. Numeric-mode
will prompt for a number, and return the number. In both cases there is an
optional "default" which will be returned if the user simply hits CR
(enter).
Ask.Com is used with a command-line argument of the form:
Ask <Function> <optional default>
Function can be any of:
H for a help message.
W for licensing info.
A for Alpha-mode.
N for Numeric-mode.
Default can be any number from 0 thru 255.
Ask.Com is one of several utilities developed by G.K. Pace being
marketed as "Share-Ware" by PaceSoft Utilities. It is Copyrighted, and all
rights are reserved by G. K. Pace. Unlicensed use is prohibited, however
you are incouraged to try Ask for a brief "trial" period (30 days). If you
find it of use to you, and desire to continue to use it, you must register
it! Single-user/single-system, non-commercial users may obtain a license for
the use of Ask.Com by sending $10.00 to PaceSoft Utilities. You will recieve
a license for use, a copy of the latest version, and possibly some other
useful utilities to try out. Commercial or other useage will require a
negoitiated license contact PaceSoft Utilities for further information.
Thank you for trying Ask.Com... I sincerely hope you find it of use to
you.
G. K. Pace
PaceSoft Utilities
3935 Baker Ave.
Titusville, Fl. 32796
(407)269-3088 (voice)
(407)269-9844 (BBS)
FidoNet @ 1:374/26