EasyManua.ls Logo

Commodore PC - Page 157

Commodore PC
414 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
n
n
n
n
D
n
n
n
n
n
n
n
Set
Purpose:
Sets
one
string
of
characters
in
the
environment
equal
to
another
string
for
later
use
in
programs.
Syntax:
set
[string
=
[string]]
Comments:
You
should
use
the set
command
only
if
you
want
to
set
values
for
programs
you
have
written.
When
ms-dos
sees
a
set
command,
it
inserts
the
given
string
and
its
equivalent
into
a
part
of
memory
reserved
for
the
environ
ment.
If
the
string
already
exists
in
the
environment,
it
is
replaced
with
the
new
setting.
If
you
specify
just
the
first
string,
set
removes
any
previous
set
ting
of
that
string
from
the
environment.
Or
if
you
use
the set
command
without
options,
ms-dos
displays
the
current
environ
ment
settings.
When
batch
processing,
you
can
also
use
the
set
command
to
define
your
replaceable
parameters
by
name
instead
of
by
number.
For
example,
if
your
batch
file
contains
the
statement
"type
%file%",
you
could
use
the
set
command
to
set
the
name
that
ms-dos
will
use
for
that
variable.
In
the
following
command,
for
example,
set
replaces
the
%file%
parameter
with
the
filename
taxes.86:
set
file=taxes.86
To
change
the
replaceable
parameter
names,
you
don't
need
to
edit
each
batch
file.
Note
also
that
when
you
use
text
(instead
of
a
number)
as
a
replaceable
parameter,
the
name
must
be
ended
by
a
percent
sign.
The
set
command
is
especially
useful
in
the
autoexec,
bat
file,
because
it
lets
you
automatically
set
strings
or
parameters
when
you
start
ms-dos.
See
Chapter
4,
"Batch
Processing,"
for
more
information
about
the
autoexec
bat
file.
MS-DOS
Commands
85
Set
i
Defining
replaceable
parameters
n
n

Related product manuals