Hidden COMMAND.COM Switches
To get the list of the whole COMMAND.COM switch, type the /? the command prompt. But the thing is, we now have 3 switches that are not documented at all, not even under the /? list. So, now let us have a brief explanation.
The first switch is the /D switch. COMMAND /D used on the CONFIG.SYS SHELL= line (the primary shell), or at the MS-DOS prompt (secondary shell in combination with the COMMAND /P parameter), prevents the execution of the AUTOEXEC.BAT file at bootup. Example:
SHELL=C:\COMMAND.COM C:\ /E:512 /D /P
The next switch is the /F. Remember the annoying "Abort,Retry, Fail" error? Most of us usually just select "Fail". This is exactly what the switch does - it will automatically reply with a "Fail" if the floppy disk drive is not ready or available. You can activate it on the CONFIG.SYS file SHELL= line. Example:
SHELL=C:\COMMAND.COM C:\ /E:512 /F /P
or just added to any PIF file or the DOS Prompt shortcut through "Command.Com /F"
The third switch is th /Z. This will display "errorlevel" return code messages after executing each external DOS command - which is normally used to examine the return code for use of batch files. This switch can be activated through the CONFIG.SYS file SHELL= line. Example:
SHELL=C:\COMMAND.COM C:\ /E:512 /P /Z
It can also be used in a Windows PIF file. You should see the below message:
"Microsoft(R) Windows 95 (C)Copyright Microsoft Corp 1981-1996. Return code (ERRORLEVEL): 0 WARNING: Reloaded COMMAND.COM transient"
|Home, Links, Awards, Help, Map, Poll, Newsgroups, Online Chat, Mailing List, Search|
|Tips & Tricks||Guides||Bugs & Fixes||Themes||Reviews||Site Contents||ActiveIE|
1998-1999 The Active Network. All rights reserved.