How to use MS-DOS

From ArticleWorld


Although MS-DOS has long been replaced on most machines, it is still useful to know how to use the MS-DOS prompt. Not only because this will often allow you to "resurrect" some old machines, but also because the MS-DOS interpreter itself has remained an important component of even Windows XP and 2003. Here is a quick introduction to using the prompt.

Basic operations

You can get to the MS-DOS prompt either by using an MS-DOS installation, or by using Windows' command interpreter. The later is located in the Accessories folder of the Start menu.

The first thing you will see is probably:

C:\>

This is known as the DOS prompt. The C:\ represents the current location in the directory structure, and the ">" means that the interpreter is waiting for you commands.

The first command you will learn is "dir". This lists the names of the files in the current directory:

C:\>dir

Note that the prompt is not case sensitive. Dir, DIR, dir and DiR are the same to it. The dir command also has support for wildcards. Therefore, to list all the files that end with .EXE, we can write:

C:\>dir *.EXE

You will also be able to change the current directory, using the cd command:

C:\>cd C:\Progra~1

Note that, on older DOS interpreters, the file names are truncated if they are longer than 8 characters. The first six letters remain. The last two are used to recognize the actual file: ~1 means the first file name in alphabetical order, ~2 represents the second one and so on.

You run a program by simply typing its name. Programs can be recognized because their names end with .EXE.

Notes

You can see all available commands by typing:

C:\>HELP