Equal-Sign Characters as Arguments in Batch Files (35938)
The information in this article applies to:
• Microsoft MS-DOS operating system 3.1
• Microsoft MS-DOS operating system 3.2
• Microsoft MS-DOS operating system 3.21
• Microsoft MS-DOS operating system 3.3
• Microsoft MS-DOS operating system 3.3a
• Microsoft MS-DOS operating system 4.0
• Microsoft MS-DOS operating system 4.01
• Microsoft MS-DOS operating system 5.0
• Microsoft MS-DOS operating system 5.0a
• Microsoft MS-DOS operating system 6.0
• Microsoft MS-DOS operating system 6.2
• Microsoft MS-DOS operating system 6.21
• Microsoft MS-DOS operating system 6.22
This article was previously published under Q35938
Using batch files in MS-DOS, it is not possible to include an equal
sign as an argument to a batch file. The batch file parser considers
this to be a delimiter, such as a space or tab character. Thus, using
the following one-line batch file (named TEST.BAT):
If the following is entered:
it would produce the following output
which shows that the batch file parser considers "one" the first
argument, and "two" the second argument, with the equal sign being a
delimiter. This makes it impossible to enter equal signs in batch
files as command-line options.
Modification Type: |
Major |
Last Reviewed: |
5/12/2003 |
Keywords: |
KB35938 |
|