Thus, if the default directory were WORDPROC (in the above example), the pathname . . \DOS would tell MS-DOS to move up one level from WORDPROC (in this case to the root directory) and then find a subdirectory called DOS.

You can use either relative or absolute pathnames at any time, as long as you give MS-DOS enough information to find the directory or file at the end of the pathname.

Including Filenames With Pathnames

You usually use a pathname when you want to access a file that is not stored in the current default directory. The name of the file you want to access is specified at the end of the pathname, like this:

TYPE \WORDPROC\PERSONAL\JEANl204.DOC

This command tells MS-DOS to list on screen (TYPE) the contents of the file JEAN1204.DOC, which is stored in the directory \ WORDPROC \ PERSONAL. Note that the filename is connected to the pathname by a backslash character-the same character used to separate the various directories in the pathname itself.

Including Drive Letters With Pathnames and Filenames

As explained earlier, if you want to access a file stored on a drive other than the default drive, you have to include a drive designator (A:, for example) along with the filename. Likewise, if the file you want is not stored in the default directory of that drive, you need to include a pathname as well as the drive designator.

For example, suppose you are logged onto the root directory of drive A, and you want to delete the file JEAN1204.DOC, which is stored in the directory \WORDPROC\PERSONAL of drive C. Enter the command as follows

DEL C:\WORDPROC\PERSONAL\JEANl204.DOC