HSGXTSXV

Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 13

MS-DOS (Microsoft Disk Operating System)

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Some terms about Ms-Dos :-

Disk

File

File Name

Directory

Path

Command

Prompt

Disk : It is a magnetic slot or cassette where the data of computer is saved.

3 1/2" Floppy Disk => A:

5 1/4" Floppy Disk => B:

Hard Disk => C: (If 5 Partition then C: D: E: F: G:)

Compact Disk => D:

DVD/Pen Drive/Memory Card => E:\ to............ Z:\

File : It is the location or place where data are saved by name. Documents,

Photo, Songs, Movie etc..

File Name : It is the name of the data group; by which name we can identify

it. A file name is devided into three part. i.e. Primary name, Separator,

Extention name

Ram . txt

^^^^^ ^^^ ^^^^^

P.N Separator Extention name


The Primary name should be <= 8 Character

The Extention name should be <= 3 Char.

Directory : It is the alternate then an Almirah. Like as files are stored in an


almirah. or All the files are stored to make separate group in a directory.

Path : It is the Way of the Directory and subdirectory.

e.g. => C:\Windows\Command\Ebd\ram.txt

It means the "ram.txt" file is situated in the C drive; in c drive

windows directory; in the windows directory the command dir is present,

and then inside the command dir the ebd dir is present and inside the

ebd directory the file is present.

N.B. : the directory are separated by the back slash "\" symbol.

Prompt : It is the symbol which comes at the first of DOS Operating system.

Every command should be given in front the prompt. i.e "C:\>"

C:\WINDOWS>

Command : It is the Executable word by the computer. to which computer can

understand.

e.g. => dir, date, time, vol, ver ..... etc...

The commands are two types. 1 : Internal Command 2: External Command

Internal Command : It is otherwise called as memory resident command.


While

the computer starts it autometically loaded into the memory. It will must

execute immediately. these commands are included with the command.com file.

External Command : It is also called as disk resident command. It loaded into


memory while the command is given. The execution is very late to load. These

command are present in the Directory c:\windows\command\

I N T E R N A L C O M M A N D

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Some Sample Dos Commands :-

DIR CLS DATE TIME VOL VER COPY CON TYPE


REN DEL MD CD RD CD\ CD.. PROMPT PATH COPY

DIR

=====================

Displays a list of files and subdirectories in a directory.

Specifies drive, directory, and/or files to list.

(Could be enhanced file specification or multiple filespecs.)

/P Pauses after each screenful of information.

/W Uses wide list format.

/A Displays files with specified attributes.

attributes D Directories R Read-only files

H Hidden files A Files ready for archiving

S System files - Prefix meaning not

/O List by files in sorted order.

sortorder N By name (alphabetic) S By size (smallest first)

E By extension (alphabetic) D By date & time (earliest first)

G Group directories first - Prefix to reverse order

A By Last Access Date (earliest first)

/S Displays files in specified directory and all subdirectories.

/B Uses bare format (no heading information or summary).


/L Uses lowercase.

/V Verbose mode.

Switches may be preset in the DIRCMD environment variable. Override

preset switches by prefixing any switch with - (hyphen)--for example, /-W.

WILD CARD CHARACTER


=======================
When we want to find a file from their name or first name or extention name we can
find the file through the wild card character star "*" and Question mark "?"
Here * is used to find a string and "?" is used to find a text.

For example :

Find those files whose extention name is .txt

C:\> dir *.txt

Here star means all files; files started with any name but extention name
should be .txt

Like :
saroj.txt
sunita.txt
sumeet.txt
sriya.txt

Find those files which are started with "S" name

C:\> dir s*.*

Here it will show all files started with s name like

saroj.txt
sunita.txt
sumeet.txt
sriya.txt
sita.mp3
surya.bmp
etc...
Question Mark (?)

Used to find single letter. Find those files which name are three letters

C:\> dir ???.*

It means three character and extention name any text

CLS => To Clear the Screen

DATE => To See & Change Current System Date


Current date is Thu 10-08-2002

Enter new date (mm-dd-yy):

TIME => To See & Change Current System Time

Current time is 08:20:26.86p

Enter new time :

VOL => To See Current Volume of the Disk

VER => To See Current Version of the Operating System

COPY CON

^^^^^^^^^^^^^^^^^

To create a new file.

SYNTEX : COPY CON <FILE NAME>

EXAMPLE : COPY CON RAM.TXT

After creating a file; we need to save the file. To save a file press f6 or

CTRL+Z .

TYPE

^^^^^^^^^

Displays the contents of text files.

TYPE [drive:][path]filename

REN

^^^^^^^^
Renames a file/directory or files/directories.

RENAME [drive:][path][directoryname1 | filename1] [directoryname2 | filename2]

REN [drive:][path][directoryname1 | filename1] [directoryname2 | filename2]

Note that you cannot specify a new drive or path for your destination.

Deletes one or more files.

DEL

^^^^^^^^^^^

DEL [drive:][path]filename [/P]

ERASE [drive:][path]filename [/P]

[drive:][path]filename Specifies the file(s) to delete. Specify multiple

files by using wildcards.

/P Prompts for confirmation before deleting each file.

MD

^^^^^^^^^

MAKE DIRECTORY: To make a directory.

Example : MD SUBASH

CD

^^^^^^^

CHANGE DIRECTORY : To entry to the directory

If you want to enter to the subash directory.......

C:\>cd subash

C:\SUBASH>
It means you are now in subash directory.

CD..

^^^^^^^^

It returns to the previous directory.

CD\

^^^^^^^

It returns to the root directory.

RD

^^^^^^^

To remove a directory. Note : The directory must be empty else it will not

remove the same.

PROMPT

^^^^^^^^

Changes the Windows command prompt.

PROMPT [text]

text Specifies a new command prompt.

Prompt can be made up of normal characters and the following special codes:

$Q = (equal sign)

$$ $ (dollar sign)

$T Current time

$D Current date

$P Current drive and path

$V Windows version number


$N Current drive

$G > (greater-than sign)

$L < (less-than sign)

$B | (pipe)

$H Backspace (erases previous character)

$E Escape code (ASCII code 27)

$_ Carriage return and linefeed

Type PROMPT without parameters to reset the prompt to the default setting.

P A T H
======================

Path command is to view or set a path for a system executable file. i.e. ".Exe" &
".Com" Files. It's Default path is "C:\WINDOWS;C:\WINDOWS\COMMAND"
Because all the ms dos command files and windows executable files are present in
the path.

If you will change the path of system then the system may not work the external
commands.

C:\> path

To view the current path

C:\> Path=C:\rama

To change the path


C O P Y
============
Copy command is used to create a duplicate files in the same directory or another
disk. Suppose you want to copy the same files in the floppy then you have to use
the copy command to create a duplicate file.

Syntex :

C:\> COPY <filename> <target location>

For Example :

C:\>

E X T E R N A L - C O M M A N D

^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

LABEL CHKDSK XCOPY MEM DISKCOPY FC DISKCOMP


MOVE SYS DELTREE MODE DOSKEY FIND PRINT

EDIT SORT ATTRIB HELP MORE

LABEL : To change the volume label of the operating system.

CHKDSK : To check the disk. it show us the free space, used space, no. of files, No
of folders, No of hidden files etc...

XCOPY/S : To copy the all files of the same directory as well as it sub-
directories.

MEM : To see the used memory, free memory, convensional memory. .. . etc...

C:\> mem

Memory Type Total Used Free

---------------- -------- -------- --------

Conventional 640K 55K 585K

Upper 0K 0K 0K

Reserved 384K 384K 0K

Extended (XMS) 15,360K 168K 15,192K

---------------- -------- -------- --------

Total memory 16,384K 607K 15,777K

Total under 1 MB 640K 55K 585K


DISKCOPY : To make a duplicate disk of the source disk.

FC : Compares two files or sets of files and displays the differences between them.

/A Displays only first and last lines for each set of differences.

/B Performs a binary comparison.

/C Disregards the case of letters.

/L Compares files as ASCII (American Standard Code for Information


Interchange) text.

/N Displays the line numbers on an ASCII comparison.

/T Does not expand tabs to spaces.

/W Compresses white space (tabs and spaces) for comparison.

DISKCOMP : Compair two disk.

syntex : C:\> diskcomp <disk1> <disk2>

Exapmpe : C:\> diskcomp a: a:

MOVE : To move a directory or file from the current location to the target
location.

Example : C:\> move C:\sanjay\rama.txt C:\student\bikash

It means it will move the rama.txt file to the student directory. At the end
of the move it will show the confirmation (OK or the Problem)

SYS : It is used to create a bootable disk. It will copy all the system files i.e.
io.sys, msdos.sys, command.com, drvspace.bin to the target location. the
bootable disk will help you when the computer will unable to start; enter the
bootable disk it will boot and give you the command prompt "A:\>"

Example : Sys A:
It will copy these system files from the computer to the floppy.

DELTREE : It is used to the delete the whole directory as well as all the sub-
directory. Use the command only to your own directory else it may cause harm
to the computer.

Example : C:\> deltree rama

It will delete the rama directory and all it subdirectory

Configures system devices.

MODE : To change the View of the Screen Text

Mode 40 (40 letters per screen)

Mode 80 (80 letters per screen)

DOSKEY

MACRO Specifies macro to a command for which we can access the command

by the given macro name

Ex: Doskey ram=dir

UP,DOWN arrows recall commands

Esc clears current command

F7 displays command history

Alt+F7 clears command history

[chars]F8 searches for command beginning with [chars]

F9 selects a command by number

Alt+F10 clears macro definitions

Ctrl+T Command separator: allows multiple commands in a macro

FIND : Find all the text in a file


Syntex : Find "Ramachandra" ram.txt

It will find the specified text in the file ram.txt

PRINT(>>)Print command is used to print the displayed text inside a file

Ex: Dir >> Ram.txt

It will print all the list files and directory which shows in the screen print

inside the ram.txt file.

EDIT : It is a free text editor; where we can change the text, modified the

text, save, Print & Reopen the saved file.Also can change the colors, search

any text etc...

SORT : To Sorting the contains of the file. It will put all the text in an

ascending order like dictonary.for which we can able to find the specified

line & Paragraph, List names etc...

ATTRIB : To change the attribute of the file to Set Delete

# Read-Only +R -R

# Archieve +A -A

# System +S -S

# Hidden +H -H

Syntex : C:\> Attrib ram.txt +h

Now the ram.txt file is hide; we can't see it with dir command

FORMAT : (Only For Engineers)

Formats a disk for create new sectors and tracks. When we buy a new

floppy we shold format the floppy to create new track and sector.Don't
Use this command in Hard Disk.It may Delete all data permanently from

the computer and may create bad sector or disk may unusable.

N.B : Now Many Floppy are pre-IBM Formatted

Syntex : C:\> Format A:

HELP : To see the help Index of the Command.

Syntex : Command/?

Example : C:\> Dir/?

It will show all the help about the dir command

How to Start Ms-Dos

1. Start => Program => Ms DOS Prompt


2. Start => Run => Command => Ok
3. Double Click on Ms Dos Icon on the Desktop
4. Start => Shut Down => Restart in Ms Dos Mode => Ok
5. Press F8 repeatedly at the time of booting and the Choice menu choose the 5th
option "Command Prompt Only" => Press Enter

asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj
asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj
asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj asdf ;lkj

You might also like