MS-DOS COMMMANDS: A COMPREHENSIVE LIST COMMAND SYNTAX DESCRIPTION ================================================================================ CD CD [drive:][path]Change Changes the current directory to the specified path or drive. DIR DIR [drive:][path] Displays a list of files and subdirecto- ries in a directory. COPY COPY [source] [destina- Copies files from one location to ano- tion] ther. DEL DEL [drive:][path] Deletes one or more files. REN REN [drive:][path][file- Renames a file or directory. name1] [filename2] MKDIR MKDIR [drive:][path] Creates a new directory. RMDIR RMDIR [drive:][path] Removes an existing directory. TYPE TYPE [drive:][path] file- Displays the contents of a text file. name EDIT EDIT [drive:][path]file- Opens the MS-DOS text editor for editing name a specified file. CHKDSK CHKDSK [volume:][[path] Scans and fixes errors on a disk. filename] [/F] [/V] [/R] [/X] [/I] [/C] [/L[:size]] [/B] FORMAT FORMAT volume [/FS:file- Prepares a storage medium for data system] [/V:label] [/Q] storage. [/L[:size]] [/A:size] [/C] [/X] XCOPY XCOPY [source] [destina- Copies files and directories, including tion] [/E] [/C] [/H] [/R] subdirectories. [/Y] TREE TREE [drive:][path] Graphically displays the folder structure of a drive or path. DATE DATE [MM-DD-YYYY] Displays or sets the system date. TIME TIME [HH: MM: SS] Displays or sets the system time. HELP HELP [command] Provides help information for MS-DOS commands. EXIT EXIT Exits the MS-DOS command prompt or a batch file. ATTRIB ATTRIB [+ R|-R] [+A|-A] Sets or clears file attributes [+ H|-H] [+ S|-S] (Read-Only, Archive, System, Hidden), [d:][path]filename [/S] managing file visibility and access in MS-DOS. MODE MODE [device] [BAUD=b] Configures system devices. [PARITY=p] [DATA=d] [STOP=s] DISKCOPY DISKCOPY [drive1:][path1] Copies the contents of one disk to [filename1] [drive2:][pa- another. th2][filename2] MEM MEM[/program|/debug|/clas- Displays the amount of used and free sify|/free|/module(name)] memory in the system. [/page] SCANDISK SCANDISK [/SURFACE] [/AU- Scans and fixes disk errors. TOFIX] [/CHECKONLY] UNDELETE UNDELETE [drive:][path] Restores a deleted file. [filename] ASSIGN ASSIGN [drive1:=[drive2:]] Redirects requests for drive letters to a different drive. FDISK FDISK Manages disk partitions. BACKUP BACKUP [source] [destina- Backs up files and directories. tion] [/S] RESTORE RESTORE [source] [destina- Restores files and directories from a tion] [/S] backup. MSCDEX MSCDEX [/D: driver Provides CD-ROM access. /L:drive] [/M:bufsize] [/E /S /V] SYS SYS [drive1:][path] Transfers system files to a disk. SHARE SHARE [/F:(space)] Installs file-sharing and locking [/L:(locks)] capabilities. SMARTDRV SMARTDRV [size] [/E /V] Disk caching utility. [/C] [/L:size] SETVER SETVER [drive:][path] Sets the MS-DOS version number for a filename [/B:bytes] program. ASSIGN ASSIGN [/D] Disables automatic drive-letter assign- ments. FASTHELP FASTHELP [command] Provides a quick overview of MS-DOS com- [command] /? mands. FC FC [/A] [/C] [/L] [/LBn] Compares two files or sets of files and [/N] [/OFF[LINE]] [/T] displays the differences between them. FIND FIND [/V] [/C] [/N] [/I] Searches for a text string in files. [/OFF[LINE]] "string" [[drive:][path]file- name[...]] MORE MORE [filename] Display the content of a text file one screen at a time. ECHO ECHO [on/off] This command can either show or hide the text of the commands you type. Command echoing is on by default. ECHO ECHO [] Specifies the text to display on the screen. PATH PATH [[drive:][path] Displays or sets a search path for exe- [;...]] cutable files. SET SET [variable=[string]] Sets or displays environment variables. VOL VOL [drive:] Displays a disk label and serial number. SUBST SUBST [drive1: [drive2:] Associates a path with a drive letter. path] EDLIN EDLIN [drive:][path][file- Edits text files. name] DEBUG DEBUG [drive:][path][file- Starts the Debug program for testing and name] debugging assembly-language programs. HIMEM.SYS HIMEM.SYS [/TESTMEM:off] Provides upper memory block (UMB) and [/HMAMIN=amount] high memory area (HMA) support. UNFORMAT UNFORMAT [drive:][path] Restores a formatted disk. GRAPHICS GRAPHICS [type] [[drive:] Enables output of graphical screen con- [path]filename] [/R] [/B] tent to print. [/LCD][/PRINTBOX:STD| /PRINTBOX:LCD] QBASIC QBASIC [drive:][path] Starts the MS-DOS-based application for creating and running BASIC programs. KEYB KEYB [/CODEPAGE=page Configures a keyboard for a specific [,country]] [/E] language. CHOICE CHOICE [/C:choices] [/N] Provides a prompt with a list of choi- [/S] [/T:c,nn] ces. DISKCOMP DISKCOMP [drive1:][drive2:] Compares the contents of two floppy disks. PRINT PRINT [/D:device] [file- Sends a text file to a printer. name] SORT SORT [drive:][path][file- Sorts the contents of a text file. name] APPEND APPEND [[drive:]path[;...]] Sets or displays the search path for da- ta files. ASSOC ASSOC [.ext[=[fileType]]] Associates file extension with a file type. LABEL LABEL [drive:][label] Creates, changes, or deletes the volume label of a disk. RECOVER RECOVER [drive:][path][fi- Recovers readable information from a bad lename] or defective disk. FASTOPEN FASTOPEN [/X] [drive:] Speeds up the opening of files. [path] [/R] GOTO GOTO