SET+Setting Operating Parameters
Inserts specified names (strings) into the command
MS-DOS equivalent: SET (2.0+)
SET [name = [parameter]]
name Specifies a variable.
[parameter] Specifies a new value for the environment.
SET is used to pass arguments to application programs or to
batch files that look into the DOS environment for operating
SET FIL = \PROGFIL
instructs DOS to look in the \PROGFIL directory when an
application program interrogates the environment for FIL.
displays the names that have been set in the environment, such as
the path and the prompt.
SET NAME = HAROLD
allows you to call the value assigned to NAME from a batch file.
In the batch file, you must enclose the variable NAME in percent
signs, which indicate to DOS that a variable is being used rather
than a command-line argument (see Appendix A for more information
about batch files and using variables in them). To call the value
assigned to NAME- -for example, to change to Harold's directory-
-you would enter the line in the batch file as
If ECHO were on, you would see
when this line was executed.
To remove a string from the environment, you merely repeat
the SET command using the name parameter without specifying any
other parameter. For example, to remove NAME = HAROLD from the
environment, simply enter
SET Name =
All names are converted to uppercase in the environment, but
parameters will remain uppercase and lowercase as you enter them.
The SET command is useful for allowing application programs or
batch files to be written generically while you assign values
dynamically in the course of a program or batch file.
One of the strings placed in the environment automatically
is the COMSPEC= parameter, which describes the path that DOS uses
to reload the command processor when required. To use a command
processor other than COMMAND.COM, you need to use the COMSPEC=
parameter in the SET command. Always use the drive letter in the
path used to describe the location of COMMAND.COM or your own
[For related topics, press R]
|file: /Techref/dos/command/set.htm, 2KB, , updated: 1999/2/20 10:24, local time: 2018/1/17 14:44,
|©2018 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?|
<A HREF="http://www.piclist.com/techref/dos/command/set.htm"> dos command set</A>
|Did you find what you needed?|
PICList 2018 contributors:
o List host: MIT, Site host massmind.org, Top posters @20180117
* Page Editors: James Newton, David Cary, and YOU!
* Roman Black of Black Robotics donates from sales of Linistep stepper controller kits.
* Ashley Roll of Digital Nemesis donates from sales of RCL-1 RS232 to TTL converters.
* Monthly Subscribers: Gregg Rew. on-going support is MOST appreciated!
* Contributors: Richard Seriani, Sr.
Welcome to www.piclist.com!