0% found this document useful (0 votes)
225 views18 pages

Dos

This document provides an overview of the Disk Operating System (DOS) and basic DOS commands. It describes DOS as the operating system software that manages storage devices and information. It then outlines directories, file management, disk operations and other basic commands in DOS like DIR, COPY, DEL, FORMAT, and ATTRIB. It also provides examples of using these commands and special characters used in filenames.

Uploaded by

vampire_459
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
225 views18 pages

Dos

This document provides an overview of the Disk Operating System (DOS) and basic DOS commands. It describes DOS as the operating system software that manages storage devices and information. It then outlines directories, file management, disk operations and other basic commands in DOS like DIR, COPY, DEL, FORMAT, and ATTRIB. It also provides examples of using these commands and special characters used in filenames.

Uploaded by

vampire_459
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 18

Disk Operating System

About DOS Refers to operating system software used in most computers that provides management of storage devices and the information on them. IBM-DOS or PC-DOS, MS-DOS

Command prompt

This is called the command prompt or DOS prompt. The flashing underscore next to the command prompt is called the cursor.

Basic DOS commands A. The Directories 1. To go back one subdirectory at a time: CD.. Ex. C:\ >dir1\subdir1\CD..

2. To go back to root directory: CD\ Ex. C:\ >dir1\subdir1\CD\

Basic DOS commands A. The Directories 3. To go to a subdirectory at a time: CD <subdir name> Ex. C:\ >CD Music

4. To change root directory:

<rootdir name>:
Ex. C:\ >D:

Basic DOS commands A. The Directories 5. To list the files in a directory: DIR Ex. C:\ >DIR

6. To list the files in a directory with extended function: DIR/? Ex. C:\ >DIR/?

Ex.

C:\ >DIR/p

Basic DOS commands A. The Directories 7. To list the files in another directory: DIR D: Ex. C:\ >DIR D:

8. To list the files in another directory with subdirectory: DIR D:<subdir name> Ex. C:\ >DIR D:Pictures

Basic DOS commands A. The Directories 9. To create subdirectory: MD <subdir name> Ex. C:\ >MD John

10. To remove subdirectory: RD <subdir name>


Ex. C:\ >RD John

Basic DOS commands B. Working with the disk Reminder:

TAKE EXTRA PRECAUTION IN EXECUTING THESE COMMANDS!


1. To format a disk: FORMAT A: Ex. C:\ >FORMAT A:

2. To copy content of A: to B: DISKCOPY A: B: Ex. C:\ >DISKCOPY D: C:

Basic DOS commands C. Managing Files 1. To create a file: EDIT Ex. C:\ >EDIT

Basic DOS commands C. Managing Files 2. To rename a file or subdirectory: REN <oldname> <newname> Ex. C:\ >REN John.txt Joe.txt

3. To delete a file: DEL <file name>

Ex.

C:\ >DEL Joe.txt

Basic DOS commands C. Managing Files 4. To copy a file: Ex. COPY <filename> D:

C:\ >COPY John.txt D:

5. To copy files in a subdirectory: XCOPY <subdir> D: <subdir> Ex. Ex. Ex. C:\ >XCOPY Pictures D: C:\ >XCOPY Pictures D:Pictures C:\ >XCOPY Pictures D:Photos

Basic DOS commands D. Other commands C:\ >CLS C:\ >VER C:\ >VOL
(clear the screen) (displays version of OS) (displays disk volume label)

C:\ >DATE & TIME (displays and edit the date/time)


C:\ >TREE
(displays tree directory) CHKDSK: Checks for problems and repairs corrupted disks. A disk can sometimes get corrupted when, for example, the power is turned off while a program is still running. Example: CHKDSK C:

Special Characters
The ? represents any single character

Ex. C:\>DIR ?ohn.txt


The * represents any group of characters Ex. C:\>DIR *.txt

C:\>COPY *.txt D:
The following are legal and illegal characters in a filename: Legal: A-Z 0-9 $#&@!()-{}'`_~ Illegal: |<>\^+=?/[]";,* and the space

Attrib
The attrib command is used to change the attributes of a single file or a directory.
Attrib +h (hide) Attrib h (unhide)

Example:
attrib +h filename (hide) attrib h filename (unhide)

Sample Activity
1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. Go to the root directory D: (D:, CD\) Create a directory with your student ID number as the name of your directory (MD student number) Go to the directory you created (CD student number) Create a subdirectory IT111L (MD NIL) Create a file Student_List.txt (Edit) Go to IT111L Copy file Student_List.txt to subdirectory 1stSem Go to 1stSem (CD \student number\NIL\2ndSem) Create subdirectory Sked1 (MD Sked1) Create subdirectory Sked2 (MD Sked2) List all the files created in that subdirectory (DIR) Remove the subdirectory Sked1 (RD Sked1) Display tree directory (TREE) Close the command prompt (EXIT)

1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16.

Go to the root directory D: (D:, CD\) Create a directory with your student ID number as the name of your directory (MD student number) Go to the directory you created (CD student number) Create a subdirectory IT111L (MD IT111L) Create a file Student_List.txt (Edit) Go to NIL (CD IT111L) Create a subdirectory 1stSem (MD 1stSem) Go to root directory (CD\) Copy file Student_List.txt to 1stSem (COPY Student_List.txt 1stSem) Go to 1stSem (CD\student number\IT111L\1stSem) Create subdirectory Sked1 (MD Sked1) Create subdirectory Sked2 (MD Sked2) List all the files created in that subdirectory (DIR) Remove the subdirectory Sked1 (RD Sked1) Display tree directory (TREE) Close the command prompt (EXIT)

D:\111Exer Exer1 Exer1A.txt Exer1B.txt

Seatwork #1

Exer2
Exer2A Exer2A-1.txt Exer2A-2.txt Exer3 Exer3A Exer3B Exer3C Exer3C-1.txt Exer3C-2.txt

You might also like