Conditional processing symbols allow you to control the execution of commands; allowing you to issue multiple commands from the same prompt and to govern program flow based on the results of a command. Using these in special ways allow you to extend the command prompt rules. These symbols may not be part of a file name. Note that filenames and extensions can be up to 256 characters long under Windows NT/2000/XP.
The conditional processing symbols are: " * : / \ ? < >
For a complete description of conditional symbols, use the system Help (Help and Support under Windows XP) using keyword: conditional. Extensions of the command processor, CMD.EXE over COMMAND.COM are described under Help and Support keyword: CMD. General commands are described under Help and Support keyword: commands. Under Windows XP after doing this, click the "Full text search matches" bar at the bottom of the results screen.
Therefore under Windows NT/2000/XP Command Prompt, the rules are slightly different than under Windows 9x or DOS. For example, one of these differences is that an Ampersand (&) is a special character under NT/2000/XP Command Prompt (or START/RUN) command lines. In particular, & is used to separate commands and so cannot simply appear as an option to a command.
For example, the command:
PKZIP -a -ex -& a:\Zipfile.zip c:\FilesToZip
works under all Windows 9x MS-DOS Prompt (or START/RUN) but would fail under
Windows NT/2000/XP Command Prompt; in the latter case, preceed it with a
caret (^). For example:
PKZIP -a -ex -^& a:\Zipfile.zip C:\FilesToZip
When writing Batch files this must be taken into consideration.
For example, to run the above DOS PKZIP command via a .BAT file that will run under Windows NT/2000/XP Command Prompt or any other Windows DOS (prompt), one could write the DOS Batch file:
@Echo off REM Environment variable OS is set for Windows NT. if NOT "%OS%" == "Windows_NT" GoTo NotNT Echo this is Windows NT PKZIP -a -ex -^& a:\ZipFile.ZIP C:\FilesToZip GoTo Next :NotNT Echo this is NOT Windows NT PKZIP -a -ex -& a:\ZipFile.ZIP C:\FilesToZip
file: /Techref/os/win/winnt/consym.htm, 3KB, , updated: 2005/8/24 09:55, local time: 2024/12/1 17:04,
18.225.195.4:LOG IN
|
©2024 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://ecomorder.com/Techref/os/win/winnt/consym.htm"> Conditional symboles and the compatibility issues they cause</A> |
Did you find what you needed? |
Welcome to ecomorder.com! |
Welcome to ecomorder.com! |
.