internal commands.29to30
TRANSCRIPT
http://improvec.blogspot.in/1
Internal commands
http://improvec.blogspot.in/2
Objective
On completion of this period, you would be able On completion of this period, you would be able to knowto know
Conventions usedConventions used
Internal commands Internal commands
http://improvec.blogspot.in/3
Recap
DOS commands are divided into
Internal Commands
External Commands
http://improvec.blogspot.in/4
Prerequisite
What is meant by command
An instruction which is used to communicate with a computer system
We call this instruction a command
http://improvec.blogspot.in/5
Internal Commands
Internal commands are built–in commands
These commands are in COMMAND.COM program
This program is loaded with the operating system into the memory during booting
http://improvec.blogspot.in/6
Internal Commands (contd)
Remains resident in the memory as long as the computer is on
Hence they are always available to be executed
http://improvec.blogspot.in/7
Convention used in Command descriptions are
[] (BRACKETS)Items within brackets are optional
DRIVE It refers to the drive name. Example: C: A: B: etc
http://improvec.blogspot.in/8
Convention used in Command descriptions are (contd)
PATHIt refers to a directory nameSyntax :[\drive_directory] [\directory…]\ directory
PATHNAMEIt mentions the files that are to be referred in the path. It is used to locate a fileSyntax : [\drive_directory] [\directory…] \filename
http://improvec.blogspot.in/9
Convention used in Command descriptions are (contd)
SWITCHES
These switches control MS – DOS commands. They should always begin with a forward slash (/)
Example: /p /w etc
http://improvec.blogspot.in/10
Convention used in Command descriptions are (contd)
WILDCARDS
If we want to carry out a task for a group of files whose names have something in common, we can use wildcard characters to specify groups of files
http://improvec.blogspot.in/11
Wild characters DOS recognizes two wildcard characters
Asterisk(*) – represents one or more characters that a group of files has in common
Question mark(?) – represents a single character that a group of files has in common
http://improvec.blogspot.in/12
Examples of wildcards
*.txt : All files with .txt extension Examples are letter.txt, july.txt, and message.txt
report.* - All files named report with any extension.Examples: report.txt, report.let and report.wri.
http://improvec.blogspot.in/13
Examples of wildcards (contd)
M*.* : All files beginning with the letter M regardless of extension.Example are march.xls, memo.txt and madhavi.lvu
???.* : all files having 3 or less characters with or without any extensions.Examples are sun.bmp, son.bm and ab.x
http://improvec.blogspot.in/14
Internal Commands
CLS- Clears the screen, takes the cursor to the top left and the system Prompt appears at top left
VER – It displays the MS-DOS version
DEL/ERASE [drive:] pathname – It deletes the specified file or files. The wildcards (* and ?) can be used with del command to delete more than one file at a time
http://improvec.blogspot.in/15
Internal Commands (contd)
VOL [drive] – It displays the disk volume label which is optionally declared at the time of formatting
Example:C:\>VOL A :
ResultVolume in drive A is DBASEIIIVolume Serial Number is 0909-07BE
http://improvec.blogspot.in/16
Internal Commands (contd)
PROMPT [[text] [$character]…] – It changes the MS-DOS command prompt. $ character prompts are below
$t Current time $l <$d Current date $q =$n Drive letter $$ $$p Directory $e Escape$v Version number $g > $h Backspace$_ Return-Linefeed
http://improvec.blogspot.in/17
Internal Commands (contd)
DATE [mm- dd- yy] - It displays or sets the date
Example:C>DATE
Result:Current date is FRI 21-04-07Enter the new date (mm- dd- yy): 20-04-08Now the current date will be SUN 20-04-08
http://improvec.blogspot.in/18
Internal Commands (contd)
TIME [hours : minutes : seconds . Hundredths]
It allows to enter or change the time of the system and see the current time
To type a new time, the valid values are hours is 0-23, minutes is 0-59, seconds is 0-59 and hundredths of seconds 0-99
http://improvec.blogspot.in/19
Internal Commands (contd)
Example1 C>TIME
ResultCurrent time is 1:28:40.51Enter the new time : 11:07:51.21Now the current time will be ’11:07:51.21
http://improvec.blogspot.in/20
Internal Commands (contd)
Example2 C>TIME 12:07:59C>TIME
ResultCurrent time is 12:07:59Enter the new time :
http://improvec.blogspot.in/21
Internal Commands (contd)
PATH [drive:] [path] [;[drive:] [path]…]
It sets a command search path for programs not in the current directory
The above command is used to search more than one path by specifying several paths separated by semicolons
http://improvec.blogspot.in/22
Internal Commands (contd)
DIR [drive:] [pathname] [/p] [/w] – To list the files in a directory. Wildcards can also be used with Dir command
Example1C>DIR
ResultVolume in drive C is DOS400
http://improvec.blogspot.in/23
Internal Commands (contd)
Directory of C:\vinay. <dir> 1-11-90 1:05.. <dir> 1-09-90 13:05BASIC EXE 67520 19-12-90 2:13BUDGET BAS 814 1-01-91 1:45FINAN90 BAS 3456 7-07-90 7:34 5 File (s) 4329472 bytes free
http://improvec.blogspot.in/24
Internal Commands (contd)
Example2C>DIR/W
ResultSelects wide display and lists up to files lines per line
http://improvec.blogspot.in/25
Internal Commands (contd)
Example3 C>DIR/P
Result Selects page mode and makes the
directory display to pause once the screen is filled
To resume scrolling the display any key can be pressed
http://improvec.blogspot.in/26
Internal Commands (contd)
TYPE [drive] filename – It displays the contents of a text file on the screen
Example:C>TYPE message.dat>PRN
ResultIt sends the contents of file “message.dat”
to the printer
http://improvec.blogspot.in/27
Internal Commands (contd)
COPY [drive:] [pathname] [drive:] [pathnamr2] – It copies one or more files to another location
COPY pathname1 + pathname2 […]pathname.. It appends the files. Wildcards can also be used with copy command
http://improvec.blogspot.in/28
Internal Commands (contd)
Example1C>copy bpay.rpt basicpay.rpt
Result It copies a file named ‘bpay.rpt’ in the
same drive asanother name called ‘basicpay.rpt’
http://improvec.blogspot.in/29
Internal Commands (contd)
Example2C>copy BPAY.RPT A:PROLL.RPT
Result It copies a file bpay.rpt from current drive
C to drive A named as proll.rpt
http://improvec.blogspot.in/30
Internal Commands (contd)
Example3 C>COPY *.rpt + ref.txt summary.doc
Resultthe above copy command combines all
*.rpt files and ref.txt files and stores in filename called summary.doc
http://improvec.blogspot.in/31
Internal Commands (contd)
MKDIR/MD [drive:] path – This command creates required directory
ExampleC>MKDIR letters
ResultIt the above example, the command is
used to create a directory named letters
http://improvec.blogspot.in/32
Internal Commands (contd)
CHDIR/CD [path] – It changes the current directory for the specified directory
Example C>CHDIR division
ResultThe above command changes the working
directory to the directory called ‘division’
http://improvec.blogspot.in/33
Internal Commands (contd) RMDIR/RD [drive:] path – It removes a directory
from a directory structure
ExampleC>RMDIR varsham
ResultThe above command is used to remove
the directory named varshamBefore removing the directory entirely, the
directory should be empty.
http://improvec.blogspot.in/34
Summary
In this class, we have learnt about
Internal commands – COPY, DEL, DIR, TYPE, CD, MD, RD, MODE, PATH, DATE, TIME, COPY CON etc.
http://improvec.blogspot.in/35
Frequently Asked Questions
1. List any four DOS internal commands
2. What is DOS internal command?
3. Explain any four internal commands in DOS.
http://improvec.blogspot.in/36
Quiz
Internal commands are _________Answer: built in commands
http://improvec.blogspot.in/37
Quiz
The instructions which are used to communicate with the computer systema. instructionsb. commands
Answer: b
37