Avery Dennison 6037 Rev. AA 3/04 Programmer Manual User Manual

Page 20

Advertising
background image

2-10 DOS Basics

Batch File names

When naming batch files, use the .BAT extension on the file name. This
extension tells ROM-DOS to execute the batch file when its name is
entered on the command line. The name of the batch file cannot be the
name of other internal commands. For example, COPY.BAT is an invalid
batch file name.

To execute the batch file, enter the

filename on the command line. You

need not include the .BAT extension unless a file with the same file name
and a .EXE or .COM extension is present in the same directory. Batch
file execution begins when you press the Enter key.

Creating a Batch File

You can create a batch file by using any word processor or text editor
that saves output as unformatted (ASCII) text. Or you can create them by
typing directly from the keyboard into a file. This is done with the
command

COPY CON filename.BAT

This tells ROM-DOS to copy the output from the console (keyboard) to
the specified file. Once you have entered the above command, you may
enter the contents of your batch file.

At the completion of each line, press Enter. As you enter each line, you
can make corrections using Backspace and retyping. If you enter an
incorrect line or wish to discontinue without saving your work, press
Ctrl+C.

When you have finished entering all the lines in your batch file, press
Ctrl+Z and then Enter to complete the file and return to the command line
prompt.

Advertising