home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Don Maslin Archive
/
maslin_archive.zip
/
AARDVARK_Tape_Backups
/
maslin_c_d_3oct95
/
ddrive
/
sydex
/
sanyo
/
helpdex.td0
/
MS-DOS2.HDX
< prev
next >
Wrap
Text File
|
1990-02-15
|
46KB
|
1,645 lines
80/F0/07/F0/F0/F0/07
Standard MS-DOS/PC-DOS 2.XX Commands
Index
12
15 February 1990
SYNTAX Understanding the syntax. APPENDIX
KEYS Editing and function keys. APPENDIX
WILDCARDS Wild card characters ? and *. APPENDIX
IN/OUTPUT Redirection and piping. APPENDIX
CREDITS References and trademarks. HELP
-----------------------------------------
ASSIGN Assign logical drive.
BACKUP Backup hard disk.
BASIC Run GW-BASIC interpreter.
BASICA Run GW-BASIC interpreter.
BELL Install and ring system bell.
BLANKCGA Blank the CGA display.
BREAK Toggle BREAK switch.
BW Set video mode to BW80.
CD Change directory.
CHDIR Change directory.
CHKDSK Check diskette.
CLS Clear console screen.
COMMAND Load secondary COMMAND.
COMP Compare files.
COLOR Set video mode to C80.
COPY Copy files.
CTTY Change I/O device.
DATE Display and/or set date.
DEL Delete file.
DIR Display directory.
DISKCOMP Compare diskettes.
DISKCOPY Copy diskette.
ECHO Toggle console ECHO switch.
ERASE Delete a file.
EXE2BIN Convert EXE file to binary.
EXIT Terminate secondary COMMAND.
FC Compare files.
FDISK Configure the hard disk.
FIND Search file for text string.
FOR Iteration command.
FORMAT Format a diskette.
GOTO Go to a label.
GRAPHICS Enable graphics screen print.
HELP Run DOS help program.
IF Execute command on condition.
MD Make a new directory.
MKDIR Make a new directory.
MODE Set video mode and I/O ports.
MORE Output one screen at a time.
PATH Set directory path.
PAUSE Pause batch file execution.
PRINT Send file to print device.
PROMPT Change DOS command prompt.
PRTSC Enable/disable the PRTSC key.
RD Remove a directory.
RECOVER Recover the deleted file.
REM Display remark.
REN Rename a file.
RENAME Rename a file.
RESTORE Load backup to hard disk.
RMDIR Remove a directory.
SCOPY Single drive file copy.
SCREEN Set the display mode.
SET Set string value.
SHIFT Shift parameter.
SORT Sort output to terminal.
SWCHR Change the switch character.
SYS Transfer DOS system files.
TIME Display and/or set time.
TIMEPARK Park hard disk while inactive.
TREE Display the directory tree.
TYPE List file to screen.
TYPEF List file to screen.
VER Display DOS version number.
VERIFY Toggle VERIFY switch.
VOL Display the volume label.
VOLUME Label/relabel the disk.
!DOCUMENT
!ASSIGN
COMMAND: ASSIGN MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Route requests to a different drive.
SYNTAX:
ASSIGN [drive1=drive2] [...]
EXAMPLE 1:
ASSIGN A=C B=C routes all requests for drives A: and B: to drive C.
EXAMPLE 2:
ASSIGN restores all drive assignments to normal.
!BACKUP
COMMAND: BACKUP MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Back up fixed disk files.
SYNTAX:
BACKUP [drive1][path][filename][.ext] <drive2>[/S][/M][/A][/D:mm-dd-yy]
where /S causes all files in all subdirectories will also be backed up,
/M requests backup for only those files that have changed since
last backup,
/A requests backup files to be added to the diskette in the specified
drive, and
/D:mm-dd-yy requests backup of files modified on or after the
specified date.
EXAMPLE:
BACKUP C:\ A: /S backs up all files on C to A.
!BASIC
COMMAND: BASIC MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Run the GW-BASIC interpreter. Optionally executes the program name
given as a parameter. Same as BASICA.
SYNTAX:
BASIC [drive][filename]
EXAMPLE:
BASICA TEST loads the GW-BASIC interpreter and executes TEST.BAS.
!BASICA
COMMAND: BASICA MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Run the GW-BASIC interpreter. Optionally executes the program name
given as a parameter. Same as BASIC.
SYNTAX:
BASICA [drive][filename]
EXAMPLE:
BASICA TEST loads the GW-BASIC interpreter and executes TEST.BAS.
!BELL
COMMAND: BELL author unknown for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Replace the standard beep of MS-DOS with more a pleasant sounding
bell.
SYNTAX:
BELL
EXAMPLE:
BELL replaces the MS-DOS beep and sounds the bell. Place this command
in the AUTOEXEC.BAT file to install BELL at the time the system
is loaded.
!BLANKCGA
COMMAND: BLANKCGA by Rich Winkel for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Blank the CGA display after approximately 5 minutes of inactivity to
prevent permanent damage to the phospher of the CRT.
SYNTAX:
BLANKCGA
EXAMPLE:
BLANKCGA installs the memory resident program BLANKCGA to blank
the CGA display after approximately 5 minutes of
inactivity. Place this command in the AUTOEXEC.BAT file
to install BLANKCGA at the time the system is loaded.
The time delay of 5 minutes can be changed to a longer or shorter period of
time by using DEBUG to modify the byte value at locations xxxx:0131 and
xxxx:0160. The delay in seconds is 14 times the byte value. The standard
value is 15H for a delay of 14 x 21 = 294 seconds or 4 minutes 54 seconds.
Replacing 15H with 0BH would change the delay to 14 x 11 = 154 seconds or 2
minutes 34 seconds.
!BREAK
COMMAND: BREAK MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Toggle the BREAK switch ON or OFF.
SYNTAX:
BREAK [ON|OFF]
EXAMPLE 1:
BREAK ON CTRL-C and CTRL-BREAK are intercepted by DOS.
EXAMPLE 2:
BREAK OFF CTRL-C and CTRL-BREAK are ignored by DOS.
EXAMPLE 3:
BREAK responds with current status of the BREAK
switch, i.e., ON or OFF.
!BW
COMMAND: BW by Kent L. Schepler for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Set video mode and clear the console display. The video mode is set
to BW80, the display is cleared, and the cursor positioned in the
upper left corner of the display.
SYNTAX:
BW
EXAMPLE:
BW sets video mode to BW80 and clears the console display.
!CD
COMMAND: CD MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Change the current directory. Same as CHDIR.
SYNTAX:
CD [drive][path]
where drive is the drive on which the directory is to be changed, and
path is the path to specify the new directory.
If drive is omitted, the current drive is assumed. If path is omitted, the
current path is displayed.
EXAMPLE 1:
CD \ changes the directory of the current drive to the root
directory.
EXAMPLE 2:
CD \LEVEL1\LEVEL2
changes the directory of the current drive to LEVEL2.
!CHDIR
COMMAND: CHDIR MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Change current directory. Same as CD.
SYNTAX:
CHDIR [drive][path]
where drive is the drive on which the directory is to be changed, and
path is the path to specify the new directory.
If drive is omitted, the current drive is assumed. If path is omitted, the
current path is displayed.
EXAMPLE 1:
CHDIR \ changes the directory of the current drive to the root
directory.
EXAMPLE 2:
CHDIR \LEVEL1\LEVEL2
changes the directory of the current drive to LEVEL2.
!CHKDSK
COMMAND: CHKDSK MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Check the disk and report status.
SYNTAX:
CHKDSK [drive][filename] [/F][/V]
where /F requests CHKDSK to attempt to fix errors in the File Allocation
Table (FAT), and
/V is the switch to request report of progress during execution of
CHKDSK (verbose).
EXAMPLE:
CHKDSK B:/F checks drive B and attempts to fix all allocation errors.
!CLS
COMMAND: CLS MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Clear console display. Causes MS-DOS to send the ANSI escape
sequence, ESC[2J, to the console. The display is cleared and the
cursor is positioned in the upper left corner of the display. If the
ANSI driver is not installed the display will not clear but instead
display the ANSI escape sequence.
SYNTAX:
CLS
EXAMPLE:
CLS clears the console display.
!COLOR
COMMAND: COLOR by Kent L. Schepler for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Set video mode and clear the console display. The video mode is set
to C80, the display is cleared, and the cursor positioned in the
upper left corner of the display.
SYNTAX:
COLOR
EXAMPLE:
COLOR sets video mode to C80 and clears the console display.
!COMMAND
COMMAND: COMMAND MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Invoke a secondary COMMAND processor.
SYNTAX:
COMMAND [drive][path] [device][/P][/C string]
where drive and path specify the drive on which and directory in which
COMMAND.COM is to be found,
device specifies the device to be used for input and output instead
of the keyboard (not available in PC-DOS),
/P directs MS-DOS to keep the secondary COMMAND processor permanently
in memory even if the EXIT command is entered, and
/C directs MS-DOS to load COMMAND.COM as a transient secondary
processor and execute the command or program specified by string.
The /C switch must be the last switch on the command line. When the /C
switch is not used the secondary COMMAND processor remains in memory until
the EXIT command is entered.
EXAMPLE:
COMMAND /C FILE1 when issued from a batch file to run the batch file
module FILE1.BAT, executes FILE1 and then returns
control to the main batch file.
!COMP
COMMAND: COMP MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Compare files.
SYNTAX:
COMP [drive][path][filespec[.ext]] [drive][path][filename[.ext]]
EXAMPLE 1:
COMP A:FILE1 B:FILE2 compares FILE1 on drive A to FILE2 on drive B.
EXAMPLE 2:
COMP A:*.ASM C: compares all files with the extension .ASM on
drive A to the files with the same name on C.
EXAMPLE 3:
COMP A:\LEVEL1 A:\LEVEL2 compares all files in subdirectory LEVEL1 to
to the corresponding files in LEVEL2.
!COPY
COMMAND: COPY MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Copy files.
SYNTAX:
COPY <filespec1>[/A][/B] [filespec2][/A][/B][/V]
where /A causes the file to be treated as an ASCII file. When used with
filespec1, copies up to but not including the first CTRL-Z (EOF
marker). When used with filename2, causes a CTRL-Z to be added as
the last character of the file.
/B causes the file to be treated as a binary file. When used with
filespec1, the entire file based on directory size is copied. When
used with filename2, no CTRL-Z will be added to the file.
/V is the switch to turn on verification to ensure that target
sectors are written correctly.
EXAMPLE 1:
COPY A:APPLE.DOC B: copies the file APPLE.DOC to drive B.
EXAMPLE 2:
COPY A:APPLE.DOC PEAR.DOC creates the file PEAR.DOC on the default
drive and copies the file APPLE.COM to it.
EXAMPLE 3:
COPY B:*.* C: copies all files on drive B to drive C.
EXAMPLE 4:
COPY A:FILE1+B:FILE2 C:FILE3 copies A:FILE1 and B:FILE2 to C:FILE3.
!CTTY
COMMAND: CTTY MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Change to an auxiliary console.
SYNTAX:
CTTY device
EXAMPLE:
CTTY AUX assigns AUX for the system I/O. The terminal attached to the
serial port becomes the system I/O (keyboard and display)
device.
!DATE
COMMAND: DATE MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Set or read the current date.
SYNTAX:
DATE [mm-dd-yy]
or
DATE [mm/dd/yy]
EXAMPLE:
DATE 7/4/90 sets the date to July 4, 1990.
!DEL
COMMAND: DEL MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Delete/erase files from diskette.
SYNTAX:
DEL <filespec>
or
ERASE <filespec>
EXAMPLE:
DEL B:*.BAS deletes all files on B with the extension .BAS.
!DIR
COMMAND: DIR MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: List filenames on diskette.
SYNTAX:
DIR [drive][path][filename][/P][/W]
where /P pauses the display when the screen is full, and
/W generates a wide display, 5 file names per line.
EXAMPLE 1:
DIR /P displays all files on the current drive, the display
pauses when the screen is full.
EXAMPLE 2:
DIR B:*.LST displays all files on B with extension .LST.
Special shorthand notation is provided for the working directory and its parent
directory (one level up from the working directory):
. indicates the name of the working directory in
hierarchical directory listings, and
.. indicates the name of the working directory's
parent directory.
These directory entries are automatically made when a directory is created.
EXAMPLE 3:
DIR ..\.. displays the files in the parent's parent directory.
!DISKCOMP
COMMAND: DISKCOMP MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Compare diskettes.
SYNTAX:
DISKCOMP [drive1[drive2]] [/1][/8]
where drive1 and drive2 are the drives containing the diskettes to be
compared,
/1 specifies only side 1 is to be compared (default is 2 sides), and
/8 specifies only the first 8 sectors are to be compared (default
is 9 sectors).
EXAMPLE:
DISKCOMP A: B: compares the double sided 9 sector diskettes in A and B.
!DISKCOPY
COMMAND: DISKCOPY MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Copy a diskette.
SYNTAX:
DISKCOPY [drive1] [drive2][/1]
where /1 is the switch to copy one side only.
The first drive [drive1] is the source drive (copy from). The second drive
[drive2] is the target drive (copy to).
EXAMPLE:
DISKCOPY A: B: copies the diskette in A to B.
!ECHO
COMMAND: ECHO MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Inhibit screen display.
SYNTAX:
ECHO [ON|OFF|message]
where ON causes batch file commands to be displayed on the screen. This
is the default setting,
OFF prevents further display of batch file commands except message
following the ECHO command,
message is a string of text to be displayed on the console display
device.
The ECHO command is used primarly in batch files.
EXAMPLE 1:
ECHO OFF stops the display of batch file commands.
EXAMPLE 2:
ECHO THIS IS A MESSAGE displays THIS IS A MESSAGE on the screen even if
ECHO is OFF.
EXAMPLE 3:
ECHO system responds with current status of the ECHO
switch, i.e. ON or OFF.
!ERASE
COMMAND: ERASE MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Erase/delete files from diskette.
SYNTAX:
ERASE <filespec>
or
DEL <filespec>
EXAMPLE:
ERASE B:*.BAS deletes all files on B with the extension .BAS.
!EXE2BIN
COMMAND: EXE2BIN MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Convert .EXE file to .COM format.
SYNTAX:
EXE2BIN <filespec1> [filespec2]
!EXIT MS-DOS 2.XX and 3.XX
COMMAND: EXIT
TYPE: Internal DOS command.
PURPOSE: Exit COMMAND.COM and return to a previous level if one exists.
SYNTAX:
EXIT
EXAMPLE:
EXIT exits current COMMAND.COM and returns to previous level if one
exists.
This command is used when you have shelled to the DOS level from an application
program and want to exit DOS and return to the application program.
!FC
COMMAND: FC MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Compare two files.
SYNTAX:
FC [/B][/#][/C][/W] <filespec1> <filespec2>
where /B causes byte by byte (binary) comparison,
/# is the number of lines that must match to resynchronize during
an ASCII file comparison (default is 2),
/C causes case to be ignored when comparing ASCII files, and
/W causes leading and trailing spaces and tabs in text lines to be
ignored and consecutive spaces and tabs within a line to be
compressed to a single space when comparing ASCII files.
EXAMPLE:
FC FILE1.TXT FILE2.TXT compares ASCII files FILE1.TXT and FILE2.TXT
An enhanced version of the FC program is supplied with MS-DOS 3.XX. See the
standard MS-DOS/PC-DOS 3.XX index for more information.
!FDISK
COMMAND: FDISK MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Configure the hard disk.
SYNTAX:
FDISK
EXAMPLE:
FDISK runs the utility program to configure the hard disk.
!FIND
COMMAND: FIND MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Search files for strings of text.
SYNTAX:
FIND [/V][/C][/N] <string> [[drive][path]filename ...]
where string is a string of characters enclosed in quotation marks,
/V causes all lines NOT containing string to be displayed,
/C is the switch to display a count of the number of matches in the
file, and
/N is the switch to display the relative line number of each
matching line to be displayed before the line from the file.
EXAMPLE 1:
FIND "George Washington" FILE1.TXT FILE2.TXT FILE3
outputs all lines from FILE1.TXT, FILE2.TXT, and FILE3.TXT (in that order)
that contain the string "George Washington".
EXAMPLE 2:
DIR B: | FIND /V "George Washington"
outputs the names of all files on B that do not contain the string "George
Washington".
!FOR
COMMAND: FOR MS-DOS 2.XX and 3.XX
TYPE: Internal DOS batch file command.
PURPOSE: Iterative execution of command.
SYNTAX:
FOR %%<variable> IN <set> DO <command>
where variable is a dummy variable to represent a parameter in the set,
set is (<list of parameters separated by spaces>), and
command is any DOS command other than the FOR command.
EXAMPLE 1:
FOR %%X IN (*.PAS) DO COPY %%X B: copies all files with the extension
.PAS to drive B.
EXAMPLE 2:
FOR %%a IN (FILE1 FILE2) DO DIR %%a lists the directory information for
FILE1 and FILE2.
!FORMAT
COMMAND: FORMAT MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Format a diskette.
SYNTAX:
FORMAT [drive][/S][/1][/8][/V][/B]
where /S is the switch to transfer the operating system to the diskette
after formatting it,
/1 formats the diskette as single sided (default is double sided),
/8 formats with eight sectors per track (default is nine),
/V requests the volume name to be entered, and
/B leaves space on the diskette for an operating system to be
installed with the SYS command.
EXAMPLE:
FORMAT B: formats the diskette in drive B.
WARNING: The FORMAT command destroys all files on the diskette.
Enhanced versions of the FORMAT program are supplied with MS-DOS 3.2X and 3.3X.
See the standard MS-DOS/PC-DOS 3.XX index for more information.
!GOTO
COMMAND: GOTO MS-DOS 2.XX and 3.XX
TYPE: Internal DOS batch file command.
PURPOSE: Transfer control to the line following the label.
SYNTAX
GOTO label
where label is a line in the batch file containing a label that begins with
a colon.
EXAMPLE:
GOTO ABORT transfers control to the line following the label :ABORT in the
batch file.
!GRAPHICS
COMMAND: GRAPHICS MS-DOS 2.XX and 3.XX
TYPE: External DOS command. Requires printer with IBM/Epson compatible
graphics.
PURPOSE: Enable graphics screen dump to printer.
SYNTAX:
GRAPHICS
EXAMPLE:
GRAPHICS installs the graphics print routine. After this has been
done, the print screen key, PRTSC, will work when the display
is in the graphics mode. Once GRAPHICS has been executed it
need not be executed again unless the system is reset.
Enhanced versions of the GRAPHICS program are supplied with MS-DOS 3.XX. See
the standard MS-DOS/PC-DOS 3.XX index for more information.
!HELP
COMMAND: HELP HELPDEX by Kent L. Schepler for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Provide help with MS-DOS/PC-DOS 2.XX for IBM PC/XT/AT compatible
computer systems.
SYNTAX:
HELP [drive][path][hdxfilename][.ext] [command]
or, using the batch file, HELP2.BAT,
HELP2 [command]
where drive specifies the drive on which the HELPDEX data file is found,
path specifies the directory in which the HELPDEX data file is found,
hdxfilename specifies the name of the HELPDEX data file (default is
HELP),
.ext is the extension of the HELPDEX data file name (default is
HDX) and,
command is the name of a MS-DOS command.
With the HELP command, HELP.COM and all of the .HDX files are required. With
the HELP2 command, only the files HELP.COM, HELP.HDX, APPENDIX.HDX, and
MS-DOS2.HDX are required.
EXAMPLE 1:
HELP MS-DOS2 HELP displays this screen.
EXAMPLE 2:
HELP2 HELP displays this screen.
EXAMPLE 3:
HELP MS-DOS2.HDX displays index of MS-DOS/PC-DOS 2.XX commands for
IBM PC/XT/AT and compatible computer systems.
EXAMPLE 4:
HELP2 displays index of MS-DOS/PC-DOS 2.XX commands for
IBM PC/XT/AT and compatible computer systems.
EXAMPLE 5:
HELP displays directory of HELPDEX selections.
!IF
COMMAND: IF MS-DOS 2.XX and 3.XX
TYPE: Internal DOS batch file command.
PURPOSE: Conditional execution of commands.
SYNTAX:
IF [NOT] <condition>
where the condition parameter is one of the following:
ERRORLEVEL number
string1==string2
EXIST filespec
EXAMPLE 1:
IF EXIST FILE1 GOTO ABC transfers control to label :ABC if FILE1 exists
on the default drive.
EXAMPLE 2:
IF %1==DOUG ECHO HI DOUG displays the message HI DOUG on the screen if
parameter 1 was DOUG.
EXAMPLE 3:
MYPROG
IF ERRORLEVEL 2 GOTO ABORT transfers control to label :ABORT if the program
MYPROG set the ERRORLEVEL to 2 or more before
terminating.
EXAMPLE 4:
IF NOT EXIST FILE2 ECHO FILE2 NOT FOUND
displays the message, FILE2 NOT FOUND, if FILE2
does not exist on the default drive.
!MD
COMMAND: MD MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Create (make) a subdirectory - same as MKDIR.
SYNTAX:
MD [drive]<path>
EXAMPLE 1:
MD LEVEL1 creates subdirectory LEVEL1 under the current
directory.
EXAMPLE 2:
MD \LEVEL1\LEVEL2 creates subdirectory LEVEL2 under subdirectory
LEVEL1 when the current directory is the root.
!MKDIR
COMMAND: MKDIR MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Create (make) a subdirectory - Same as MD.
SYNTAX:
MKDIR [drive]<path>
EXAMPLE 1:
MKDIR LEVEL1 creates subdirectory LEVEL1 under the current
directory.
EXAMPLE 2:
MKDIR \LEVEL1\LEVEL2 creates subdirectory LEVEL2 under subdirectory
LEVEL1 when the current directory is the root.
!MODE
COMMAND: MODE MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Set the video mode of the display adaptor, configure printer,
configure serial port, or redirect output for printer.
SYNTAX:
MODE <n>
or
MODE [n],<m[,T]>
sets video display parameters, where
n = 40, 80, BW40, BW80, CO40, CO80, or MONO
m = L or R to shift the display left or right
T = test pattern requested to align the display.
MODE LPT<n>[:][width][,[lines][,p]]
sets width and line spacing of printer, where
n = 1, 2, or 3
width = 80 or 132 column print format
lines = 6 or 8 lines per inch
p = causes DOS to continually retry to send output
to printer if it is not ready (press CTRL+BREAK
to abort).
MODE COM<n>[:]<baud>[,parity[,databits[,stopbits[,p]]]]
sets serial port parameters, where
n = 1, 2, 3, or 4
baud = baud rate, e.g., 1200 or 2400
parity = o(dd), e(ven), or n(one) (default = e)
databits = 7 or 8 (default = 7)
stopbits = 1 or 2 (default = 2 if baud = 110, otherwise 1)
p = causes DOS to continually retry to send
output if device is not ready (press CTRL+BREAK
to abort).
MODE LPT<n>[:][=COM<m>[:]]
redirects output from printer port to serial port, where
n = 1, 2, or 3
m = 1, 2, 3, or 4
EXAMPLE 1:
MODE BW80 sets the CGA display adaptor to the 80 column
black and white mode for use with a composite
monochrome monitor.
EXAMPLE 2:
MODE LPT2:80 sets printer connected to LPT2 to 80 column mode,
6 lines per inch.
EXAMPLE 3:
MODE COM1:2400,n,8,1 sets serial port COM1 to 2400 baud, no parity, 8
data bits, and one stop bit (a common setting for
many BBS systems).
EXAMPLE 4:
MODE LPT1:=COM2: redirects output for LPT1 to COM2.
EXAMPLE 5:
MODE LPT1: cancels redirection of output for LPT1.
An enhanced version of the MODE program is supplied with MS-DOS 3.3X. See the
standard MS-DOS/PC-DOS 3.XX index for more information.
!MORE
COMMAND: MORE MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Display ASCII file data one screen at a time.
SYNTAX:
MORE <filename
or
TYPE filename| MORE
where filename is an ASCII text file.
EXAMPLE:
MORE <JAN.TXT passes the file JAN.TXT to the screen 23 lines at a time,
displaying the message "-- More --" at the end of each
screen, and waits for a key to be pressed before sending
the next 23 lines to the screen.
!PATH
COMMAND: PATH MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Set the PATH variable in the environment block.
SYNTAX:
PATH [[drive]path[[;[drive]path...]]
The PATH variable directs MS-DOS to search for the executable file in the
specified drive(s) and directory(s). When PATH is followed only by a
semicolon the previous PATH variable is removed from the environment block.
When no parameters follow PATH the current PATH variable will be displayed.
EXAMPLE:
PATH C:\;A:\ causes MS-DOS to search the root directory of drive C
and then the root directory of drive A for the file.
!PAUSE
COMMAND: PAUSE MS-DOS 2.XX and 3.XX
TYPE: Internal DOS batch file command.
PURPOSE: Cause execution of batch file to display a string, pause, and wait
for a key to be pressed.
SYNTAX:
PAUSE [message]
where message is any string of text and is displayed only if ECHO is ON
(see ECHO command). If the message is omitted then the message "Strike a
key when ready..." is displayed on the console display device.
EXAMPLE:
PAUSE THIS IS MY MESSAGE displays the message THIS IS MY MESSAGE on the
screen and waits for a key to be pressed.
!PRINT
COMMAND: PRINT MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Queue and print data files.
SYNTAX:
PRINT [[filespec][/T][/C][/P] ...]
where filespec specifies the file on which the PRINT command is to take
action,
/T is the switch to terminate printing and delete all file names
from the print queue,
/C is the cancel switch to remove a file and subsequent files from
the print queue, and
/P is the print switch to add a file and subsequent files to the
print queue.
When PRINT is entered without any parameters following the contents of the
print queue will be displayed.
The first time PRINT is run during a session, the operator will be prompted for
the print device. For the default device, PRN, press <RETURN>.
EXAMPLE 1:
PRINT FILE1 FILE2 adds FILE1 and FILE2 to the print queue.
EXAMPLE 2:
PRINT FILE1/C FILE2 FILE3/P seletes FILE1 and FILE2 from the print queue
and adds FILE3 to the print queue.
An enhanced version of the PRINT program is supplied with MS-DOS 3.XX. See the
standard MS-DOS/PC-DOS 3.XX index for more information.
!PROMPT
COMMAND: PROMPT MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Set new prompt.
SYNTAX:
PROMPT [prompt string]
The following special strings may also be included in the prompt string.
$$ = the $ character $t = the time
$d = the date $p = the current directory
$v = DOS version number $n = the default drive letter
$g = the > character $l = the < character
$b = the | character $q = the = character
$h = backspace and erase $e = the escape character
the previous character $_ = carriage return line feed
EXAMPLE 1:
PROMPT $n: changes the MS-DOS prompt to the default drive letter
followed by a colon.
EXAMPLE 2:
PROMPT $n:$p $h changes the MS-DOS prompt the default drive letter,
a colon, the current directory, 2 spaces, and a
backspace.
!PRTSC
COMMAND: PRTSC by Kent L. Schepler for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Enable/disable the PRTSC key.
SYNTAX:
PRTSC [ON|OFF|?]
where ON enables the PRTSC key,
OFF disables the PRTSC key, and
? returns the PRTSC key status.
When no parameter is specified or syntax is incorrect no action is taken and
the PRTSC document text is displayed on the console display device.
EXAMPLE:
PRTSC ON enables the PRTSC key.
!RD
COMMAND: RD MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Remove a subdirectory. Same as RMDIR.
SYNTAX:
RD [drive]<path>
EXAMPLE:
RD B:\LEVEL2\LEVEL3 removes the subdirectory LEVEL3 from LEVEL2.
!RECOVER
COMMAND: RECOVER MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Reconstruct a file from a disk that has bad sectors or a damaged
directory.
SYNTAX:
RECOVER <drive>
or
RECOVER <filespec>
EXAMPLE 1:
RECOVER A:APPLE.DOC reconstructs the file APPLE.DOC that has been lost
from the diskette in drive A:.
EXAMPLE 2:
RECOVER A: recovers the files on diskette in drive A:
!REM
COMMAND: REM MS-DOS 2.XX and 3.XX
TYPE: Internal DOS batch file command.
PURPOSE: Display a remark during execution of a batch file.
SYNTAX:
REM [string]
EXAMPLE:
REM Put disk in drive B:. displays the message "Put disk in drive B:." on
the screen if ECHO is ON (see ECHO command).
!REN
COMMAND: REN MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Rename a file on a diskette. Same as RENAME.
SYNTAX:
REN[AME] <filespec1> <filename2>
EXAMPLE:
RENAME APPLE.DOC PEAR.DOC changes the name of the file APPLE.DOC to
PEAR.DOC.
!RENAME
COMMAND: RENAME MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Rename a file on a diskette. Same as REN.
SYNTAX:
REN[AME] <filespec1> <filename2>
EXAMPLE:
RENAME APPLE.DOC PEAR.DOC changes the name of the file APPLE.DOC to
PEAR.DOC.
!RESTORE
COMMAND: RESTORE MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Restore files to hard disk from diskette.
SYNTAX:
RESTORE <drive1> [drive2][path][filename][/S][/P]
where /S is the switch to restore all files in all subdirectories of the
specified directory, and
/P requests prompt before restoring files that have been modified
since the last backup.
The files must have been saved to diskette with the BACKUP command.
EXAMPLE:
RESTORE A: C:*.DAT restores all files with the extension .DAT that were
backed up from the current directory.
An enhanced version of the RESTORE program is supplied with MS-DOS 3.3X. See
the standard MS-DOS/PC-DOS 3.XX index for more information.
!RMDIR
COMMAND: RMDIR MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Remove a subdirectory. Same as RD.
SYNTAX:
RMDIR [drive]<path>
EXAMPLE:
RMDIR B:\LEVEL2\LEVEL3 removes the subdirectory LEVEL3 from LEVEL2.
!SCOPY
COMMAND: SCOPY by Mark Zeiger for MS-DOS 2.XX and 3.XX
TYPE External DOS command.
PURPOSE: Copy files from diskette to diskette in a single drive system.
SYNTAX:
SCOPY <filespec1> [filespec2]
EXAMPLE 1:
SCOPY FILE1 copies FILE1 from source diskette to FILE1 on
destination diskette.
EXAMPLE 2:
SCOPY FILE1 FILE2 copies FILE1 from source diskette to FILE2 on
destination diskette.
!SCREEN
COMMAND: SCREEN by Mark Zeiger for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Set the video mode.
SYNTAX:
SCREEN <n>
where n=0 to select the 40x25 B/W text mode,
n=1 to select the 40x25 color text mode,
n=2 to select the 80x25 B/W text mode,
n=3 to select the 80x25 color text mode,
n=4 to select the 320x200 color graphics mode,
n=5 to select the 320x200 B/W graphics mode, and
n=6 to select the 640x200 B/W graphics mode.
EXAMPLE:
SCREEN 2 sets the display adaptor to the 80x25 B/W text mode.
Use the B/W modes for composite monochrome monitors, and the color modes for
color monitors.
!SET
COMMAND: SET MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Set one string equal to another in the MS-DOS environment table.
SYNTAX:
SET [string1[=string2]]
If SET is followed by only string1 then string1 is deleted from the
environment table.
SET can also be used in batch file processing to define the replaceable
parameters with names rather than numbers.
!SHIFT
COMMAND: SHIFT MS-DOS 2.XX and 3.XX
TYPE: Internal DOS batch file command.
PURPOSE: Shift command line parameters left.
SYNTAX:
SHIFT
SHIFT allows use of more than 10 parameters on batch file command lines and
also use of succesive parameters in a loop in a batch file.
EXAMPLE:
If the file TEST.BAT is invoked with the command TEST A B C and contains the
the commands
SHIFT
ECHO %1
SHIFT
ECHO %1
the first ECHO command will display B and the second will display C.
!SORT
COMMAND: SORT MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Sort text data.
SYNTAX:
SORT [/R][/+n]
where /R requests reverse order sort, and
/+n starts the sort on column n.
EXAMPLE 1:
SORT /R <UNSORT.TXT >SORT.TXT reads the file UNSORT.TXT, sorts the
records, and writes them to SORT.TXT.
EXAMPLE 2:
DIR | SORT /+14 produces a directory listing sorted by file
size (size starts in column 14).
!SWCHR
COMMAND: SWCHR by Kent L. Schepler for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Change the MS-DOS switch character, /, to another character.
SYNTAX:
SWCHR [chr|"chr"|?]
where chr specifies the new switch character, and
? returns the switch character status.
When no parameter is specified or syntax is incorrect no action is taken and
the SWCHR document text is displayed on the console display device.
EXAMPLE:
SWCHR - changes the MS-DOS switch character to -.
To make the question mark the switch character, enclose it in quotation marks,
e.g., SWCHR "?".
The switch character is the character that is used to precede MS-DOS command
line switches as in DIR/W. The / character is the default switch character for
MS-DOS. Since the UNIX operating system, after which the MS-DOS directory
structure was patterned, uses the - character for the switch character, many
MS-DOS users prefer to have the - character as the switch character.
The \ character is the character normally used by MS-DOS as the file separator
because the / character, used as the file separator character by UNIX, was
already used as the switch character in MS-DOS. When the MS-DOS switch
character is changed to a character other than the / character, either the /
character or the \ character can be used as a MS-DOS file separator character
when specifying a path.
!SYS
COMMAND: SYS MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Transfer the MS-DOS system files from one diskette to another.
SYNTAX:
SYS drive1 drive2
or
SYS drive
EXAMPLE:
SYS B: transfers the system files from the diskette in the default
drive to the diskette in drive B:.
!TIME
COMMAND: TIME MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Set or read the system clock.
SYNTAX:
TIME [hh:mm[:ss[.xx]]]
EXAMPLE:
TIME 14:30 sets the system clock to 14:30 hours or 2:30 PM.
!TIMEPARK
COMMAND: TIMEPARK by Sanford J. Zelkovitz for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Park the hard disk drive C and, if it exists, drive D during periods
of inactivity to protect surface of the hard disk(s).
SYNTAX:
TIMEPARK <n>
where n is an integer ranging in value from 1 to 9 specifying delay time in
minutes.
EXAMPLE:
TIMEPARK 2 parks the hard disk(s) after two minutes of inactivity.
Place this command in the AUTOEXEC.BAT file to install
TIMEPARK at the time the system is loaded.
!TREE
COMMAND: TREE MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Display all directory paths.
SYNTAX:
TREE [drive][/F]
where /F requests the display of the names of all files in each path.
EXAMPLE:
TREE C:/F displays the directory paths on drive C: and the names of all
files in each path.
!TYPE
COMMAND: TYPE MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: List ASCII file to the screen.
SYNTAX:
TYPE <filespec>
EXAMPLE:
TYPE A:APPLE.DOC sends the file APPLE.DOC on drive A to the screen.
!TYPEF
COMMAND: TYPEF by Mark Zeiger for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: List ASCII file to the screen. The listing pauses when any key is
pressed and starts again when any key is pressed. The listing may
also be sent to the PRN print device (printer). The listing may be
aborted by pressing the <CTRL> plus <C> key sequence or the <BREAK>
key.
SYNTAX:
TYPEF <filespec> [P[n]]
where P causes the file to be sent to the PRN device, and
n is an integer 1 through 9 to make the PRN device skip to top of
form after printing 66-n lines.
EXAMPLE:
TYPEF A:APPLE.DOC lists the file APPLE.DOC on drive A to the screen.
!VER
COMMAND: VER MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Display DOS version number.
SYNTAX:
VER
EXAMPLE:
VER displays DOS version number.
!VERIFY
COMMAND: VERIFY MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Toggle the VERIFY switch ON or OFF.
SYNTAX:
VERIFY [ON|OFF]
EXAMPLE 1:
VERIFY displays the current status of the verify switch.
EXAMPLE 2:
VERIFY ON turns verify switch ON. All data written to disk is verified.
EXAMPLE 3:
VERIFY OFF turns verify switch OFF. Data written to disk will not
be verified.
!VOL
COMMAND: VOL MS-DOS 2.XX and 3.XX
TYPE: Internal DOS command.
PURPOSE: Display volume identification label.
SYNTAX:
VOL [drive]
EXAMPLE:
VOL A: displays volume label of disk in drive A.
!VOLUME
COMMAND: VOLUME by Mark Zeiger for MS-DOS 2.XX and 3.XX
TYPE: External DOS command.
PURPOSE: Change, delete, or add the volume label of a disk.
SYNTAX:
VOLUME [drive][label]
where label is string with a length of 11 characters or less.
EXAMPLE:
VOLUME B:WORKDISK lables the disk in drive B: as "WORKDISK".
The original volume label will be detected and a new one created. If the drive
is not specified, the default drive is assumed.
To erase a volume label without replacing it with a new one, enter the VOLUME
command followed by the drive name and nothing else. To delete the volume
label on the default drive, enter the VOLUME command followed by a space and
nothing else.