Batch and command files, or "scripts", are plain text files that contain a series of commands for a command processor. They are processed in sequence when the file is executed.
Batch and command files are executed by a command processor. Which one is used depends on the file extension:
.CMD (command file), it is run
via the &os2; command processor, CMD.EXE.
The file is assumed to be a sequence of commands, unless it starts with a REXX
comment (/* ... */). In that case, it is interpreted
as a REXX script.
.BAT extension (batch files) are run
in DOS sessions
via the DOS command processor, COMMAND.COM.
Note that the &os2; command processor (CMD.EXE) recognizes the
.BAT file extension as well. If you are at a command prompt
and enter the name of a .BAT file, it will automatically launch a
DOS session.
Note that once you have created a batch or command file, you can also start it from the Workplace Shell. You can also create &link_progobjs; for batch or command files.
For additional information, select from the list below: