Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
(x)
-3 Software... 35_4g
3. I Introduction............,
.......... 35
3.2 Software and its Role ........ 35
Software..
3.3 Types of
........... 35
3'4 Software ..........."............... 35
3.4.ISystemSoftware ...................35
3.4.1.1OperaringSystem(OS) %
(x)
4.5 Process Managemgnt """' 57 -
4.5.i Process Concept """""""""' 58
4.5.2 Process Implementatiotr.:......'........ """""" 58
4.5.3 Process Scheduling """"""" 58
4.5.4 Types ofScheduler """""""' 59
4.5.5 SchedulingAlgorithms...'............... """""' 60
4.5.5.1FCFS .""" 60
5.6.4 Pascal @
Chapter - 6 Windows
(x,)
-__-______7
7. I Introduction.........
7.2 Notenad ........... lO7
.-
8. I Introduction................. 129
8.2 What is Word Processing ? .................. 129
8.3 Advantages of Word Processing Package MS-\Vord 129
8.4 MS-Office 130
8.5 WORD2000 ................ 130
8.6 Stafting MS-Word 130
8.7 Creating Word Documents .............. 132
8.7.1 To start a new word document.................. 133
8.8 Saving Word Documents .............. 133
8.8.1 Saving an Existing File in its Current Location ............... 134
8.8.2 Savingwith a DifferentName, Forrnat orLocation... 134
8.8.3 Saving to a Different Location 134
8.8.4 Saving in a Different Format ........... l3s
8.9 Opening a Document 135
8.9,1 To Open an Existing Document 135
(xiir)
.-------------7
(riv)
.-
9.9.2 Choosing Font Styles, Underlining, Color and Effects ..........'.... 154
.............
10.2.3 Spelling Checking Selected Text ........"""""" 174
10.2.4 Reproofing a Document you've Already Checked ....' 174
10.2.5 Controlling Spelling Settings .......'.'..""' 174
1 0.3 Using the Grammar Command .................. ........,...,...,..,.,.. |74
10.3.1 To CheckGrammarasyou I.vpe.......'..... ..................." 175
l0.3.2ChoosingwhichWritingStyletoApply............".... '.........'.'.....'..... 175
(xv)
ll.9Wizardand Template ..... lg4
ll'lOUsingwizard .............. rM
11.10. I UsingWizardtoCreateaLetter.........
........................ lg4
11.1 I Using Template
........... lgg
il.l l.l SelectingTemplateforaNew Document ................... lgg
ll.1l.2 CreatingaTemplate............. ................. lgg
I L 12 Copying Sfyles with the Help of Organ izer ..............
.................. 190
11.12.1 Steps to Copy a Style frorn One Document to Another
.................. 190
solved Exercises
................. I9r
Review Questions
........)..... r 92
Chapter - 12 Industries and Business Com
(xvi)'
- 14 Probtem Solving M.thndqlogy 207-275
Chapter 1tq E"htiqtg
14. I tntroduction .............. """"""" """"" 201
14.2 Steps of Probienr Solving """""""' "' 207
t4.3 tJnderstandirrg the Problenl """" """ " 201
l4.3.l ProblenrDeflnition ""'""'""""24i
14.3.2 Reqrrirements Analysis ""' 20tt
14.3.2.11nput........'..". """"' 208
l4.3.2.2Proccss '""" """ " "' 20u
l4.3.2.3OutPut " """'209
14.4 ldentification of Operations " ' '."' 209
14.4.I Relational Operators ' ""' 24{)
(n'll)
ter - 16 Visual Basic User Interlhce 1,j LZS3
16.1 Intloduction..............
16 2 overviervof tDE
.........231
' .. .....,. ...231
.,..."2-\U
rl?/ln^-l-: r,,r
r .+. I Declarine All t.o :al Variables
as Static
17.-5 Constants ... ..... .,......,,259
17 < r --^,.+:-^^ \/ ""...,...259
( rllii )
17.8.6 The Boolean Data TYPe 214
I 7 l0 D,vnarnic Arrays
:/ )
)f l
1 7. I 0. i l-"o create a dynart ic array ..........'.
1ft
17 .10.2 Preserving the Contents of Dynamic Arrays -:.ti
214
I I Commeltts ...............
I 7.
215
17.12 PRINT statement
215
11 .12.1 Print Using Comrna '.........
?15
17 .12.2 Print Using Semicolon
11 .12.3 Print LJsing
'fab furrction 216
18.2 ......'..,....
Event-Dliven Progranrming with VB "' " " 285
(;rn)
19.6 Adding Code for IVIenus .. ............,.... j45
19.7 Creatitga Menu Control Ana1, .."......." ...................34g
tr9.8 Menu Editor Pop-up Ivlenus .............. 350
Solved Exercises
........,"....... 354
Review Questions ""....".....
... 357
- 20 Control Statements in VB 3Sg_453
20.1 Introduction.............. ......... 359
20.2 A1gorit1uns.............,.....
........ 359
20.3 [ntroduction to Control S',atements
.. ... J6l
20.4 Selection (IflThen Selection Staternent)
..................3&
20.5 iflThenlElse Selection Statement
....... 365
2C,6 While/WenciRepetition Statement.....
..........."......... 371
20.7 Do While/Loop Repetition Statement .....................373
20.8 Do Until/Loop Repetition Statement
.......................316
20.9 ForAiextRepetition Statement
...........311
20. l0 SelectCase Statement.................
..... 3g5
20. i 1 Doil-oop While Repetition Staternenr
................... 391
2}.l2DolLoop UntilRepetition Statement .....................3%
20.13 Exit Do and Exit For Statements ..................
.......... 395
20.14 InputBox Funcfion
,..... 3n
Solved Exercises
,................ 400
Review Questions ............
.., 4lg
Chapter - 21 Common Dia
21.1 Introduction.......... .,.....,..............434
2l.2CommonDialogControl .... ..... ................436
21.2.1 ShowOpen& ShowSave Method
..........436
21.2.2 ShorvFont& ShowcolorMethod
..........441
21.2.2 Showprinrer & ShowHelp Method........
...................... Us
21.3 Dialog Boxes .............
......................... 447
21.4 CLrstom Controls
............ 457
Control
2l .4.1 Imagelist
.................. 45g
21 .4.2lmageComboControl
..,.....460
21.4.3 ToolbarControl
.....4&
21.4.4 SratusBarConrrol
............. 46g
21.5 MediaPlay,er Control
..................... 411
21.5.1 AMultimediaMClCorrtrolCDplayer
......413
Sofved Exercises
.........."...... 476
Review Questions ........,.-.
",. 477
UNIT 3 : RELATIONA L DATABASE N{ANAGEMENT SYSTEM
24.IISQLDataTypes .......'..514
(.'xi)
24.I2CreatingaTableUsingSQLCREATECommanci. ......,......".."...._. 514
24. i3 Describingthe Structure ofthe Table.. .................. 515
24.14 Tables in the Oracle Database ......,... 516
24.15 Querying the Data Dictionary ......,... 516
24.l6The Integrity Constraints ..........,...... 5lz
24 .16 "1 Constraint Guidelines ... ... 512
24. I 6.2 The NOT NLILL Constraints .................. 517
24. | 6.3 The DEFAULT Constraint 5i9
24.1 6.4 The IINIQUE Constraint 519
24. I 6.5 The PRIMARY KEY Constraint ......... 519
".......
24.16.6 The CHECK Conslraint 519
24. I 6.1 The FOREIGN KEY Constraint ................. 90
24.16.8 The Table Constraints 520
24. 17 Viewing Constraints 9t
24.17 .l Viewing the Columns Associated with Constraints .................. 5D
24.18 Adding a Constraint 523
24. 19 Dropping a Constraint .,................ 5n
24.20 Disabling Constraint .............
524
24.2 I Enabling Constraint
94
24.22 Alter Tabie ......... .
94
24.22.1The ADD Clause 95
24.22.2 The MODIFY Clause ..........
525
24.22.3 Dropping a Column ............. 526
21 23 Drop Table Command....
a.t I t Data
97
Manipulation Language (DML) 527
2.4.21.1 The INSERT INTO ...............
5n
24.25 The Delere Command ...............
98
Solved Exercises
529
R.eview Questions
533
Ctrra ter - 25 SQL SELECT Statement ............. . 537_578
25 I Introduction..........
537
25 2-Making A Query
537
25.i SELECTCommand
s37
25.3. I FROI\4 Clause .........
538
25.3.2 WHERE Clause ....,.,........................
25.4 Using Special Operators in Conditions
w
v3
25.4.1The IS NU[,L Clause ,.........
il3
25.4.2 TheDISTINCT Clause ..........,..
il4
25.4.3The ALI- Clause
545
25.4.4 The BETWEEN Clause ..........
fl5
25.4.5 The IN Clause
%
25.4.6The LIKE Clause ............... y7
25.4.7 Using NOT with Special Operators
........ 54g
25.4.8 Defining a ColumnAlias ...............
......... yg
25.5 Using Concatenation Operator
.......... yg
25.6 The UPDATE Comnrand
...."............... 551
25.6.1 Using Expression in UpDATE
551
25 6.2 UPDATE with lVtultiple Column
552
(xxii)
-
25.6.3 UPDAl'ErvithNLILLClause .......".. ........ 553
25.7 The Group F'unctior1s............... .......... 5-53
25.7.1 The AVG Function ............ 554
25.'i.2The MAX Function ...........,...... ............. 554
25.7"3 The MIN Function ............ 554
25.7.4'lhe SUM Function ..,............... .............. 554
25.7.5 The COUNT Function .... .............. ......... 555
25.7.6 Restricting DISTINCT clause with Function ............... 555
25.7.7 Aggregate Function in Expression ......... 555
25.7.8 Using NVL Function with Group Functions ................ 555
25.ETheGROLPBYClause ...................;....556
25.9'fhe I{AVINGCiarrs..i .........."..... .......... -s58
25.10 Nesting Group Functions "."...,........ ............,.......... 559
25.11OrderingtheDatabase......................:................ ........................559
25.l2Formatting Query Output .,............... 5A
Solved Exercises ................. 563
Review Questions ............... 575
(-rxlli)
.---------------7
(xxiv)
-
Chapter - 1
Evolutisn cf Csmputers
1.1 lntroduction
Computer is definerj in the Oxford dictionary as"'An cnrtontatic electroni.c appdrotus frr nruking culct.rlrt!ior'rs
or controlling operalions tiiut cn'e ex7tressible in tnuilerictti or logica! terins".
What is Computer ?
In simple words computer is detined as an electronic device to do arithmetic or non-arithrnetic operations-
process data with the help of ihe prograitls to soive thc given problem. Ccmputer is an eiectronic rnaclrinc. with
sonre pechanical facilities and is mainly used for Data Processing. It performs the arithmetical ancl logical
operations on the input daia and gives the desilerl ouiput. But in between the inpLrt and output therc is
sometbing called processing. lvhich carries out calculations otr data in the i-orm ol-nlttttbers. It takes rarv data
and processes it to give resriit" Input data is fed into tlre conlputel'through input dc'vice (ke1'board ctc ) attd
output is received through outpui device (printer, scteen e/c,).
Beingarnachine,cciinputerwill notperformindependentl;,orcreatively. ltwilldoonly,whatisinstructed
io do in a specific term. lt is based on a conlplex technology, but works on a sirnple principle as lbllou's :
The basic function peifonned by a computer is the execution of prograrn. A prograrr is a seqttence of
in
instructions, which operates on data to perform ceftain tasks. ln today digitai computer data is repleserrted
binary form using 0 and I rvhich is called binary digits or bits. In general computer eight bits are used to
represent a character internally. T'his allows LLp to 28 - 256 different iterns to be represented uniquely.-fhis
collection of eight bits is called a byte.
(1)
Saraqwati lnformaties practices (Xl)
It consists ot'wooden frarne with beacls strung on wires and rocls with a horizontal bar dividine
each wire
into trvc portions - heaven anC eaith. lnstead o{. l0 beads on each
wire as in the Russian abacus. the Chinese
abacus has i'ive treads on the heaven sidr: iulc hl/o on the eafih side. A bqad on
the heavqn side had a po\ryer
of i and a bead on the ear"th side a power of 2. The calcrilations were perfonLred by mpvinq
the beads tor.l,ards
the horizontal bar.
Na;:ier's Eones. Napie r's Eorres were rieviced by a Scottish rnatiiernatician John Napier
, in l6l ?. This is a
sef of eievcn botres - each bone has four tace-s 'arith numtrers itrscribed on
them in such a way that hy piacing
the bones side by- side, product-t end quotients oilarge numbers c.an be oblained. lncj,ler:iailyNapierinventej
the k:garithnls u'hich g,ave .way to the invontion uf the sliCc mle.
Otlghtred's Slitle Rule. Irlai:ie'r''s Iogariilims becanic- the basis for another famoin lnvQntion, na5rel1,, ,,Slicie
Rule". The siide rule was inr..ented br, Wiliram Cughtre,J, a tsritish mathematician, in 1620
A.D. A sunple sli,lc
rule consists of, two graduated scales. one of which slides unon the other. 81, suilabty aligning
one scale
against the other we can obtairi products quotients or other functions.
ENIAC took about 200 mrqo-secoiids to add iwo digits anci about 2400 ruicro-seconds to fessor,
John V Neumann proposed *re corceptof stored prograrnrning i.e.. the storage I in the
memory of the cornputer alon-s with the data. Using this principle, Professor Marvi:ive Wrlkes der,eloped a
computer in 19u19 kncwn as EDSAC (Electronic Deiay Storage Automatic Calcuiator).
1It used rnercury cielay lines for storage. The first cominercial productiorr of stored electronic computers
wasUNIVAC (UNfVersaL Autornatic Conrputer). During thispeuod.computer pro,+.uruning was mairrl.y cione in
the machine language. Assenibiy ialrguage was introduced during the early fifiiest
Charactenstics of First Genelalion cf Cornputers :
Integated Circuit
0.1 inch
'.{ this g.n.j1r,:I: size of main memory reached about 100 megabytes.:The combined effects of'high
memorv, porverftll CPt-i and large disk memories led to the development of T'irne
Shared operating Systerns.
high level languages were developed dui ing this period like FORTRAN
Uorher
'Man) lmportant on-line s)'stems like airline reservation, IV COBo L-lg.pLll etc.
dynamic production contro-I, interactive qucry
ahd inte-grated data base managernent systerns emerged on the globai software
sccnario.
Evolution of Computers
ooo
ooo
a*o
QOO
ooQ
ooo
QOOOr)OOOOOGOO
Or).IOOOOC C,OOOL)
ooLjcoo60( Pin
s).
C Magnetic disk secondary storage.
O Qa-line. real time processing.
fL"M ulti-programming operating system.
O Easter than previous generation computers.
El-'inaproved input and output devices.
EL-- Concept of multi-programining was used.
C[. 4etter storage devices (tapes).
Examples ofthird generation computers include IBIVI/360/370, NCR 395 and Burroughs 86500.
m Organic cirips,
n Decreasing costs of softr,r,are
C Decreasing costs of harclware
tr Vast itnprovements in the price-perfonxance ratto.
A Persor,al computers to be used.
O Large data storage facility.
Evolution of Computers
D Artihciallntelligence.
f, High speed processing.
tr Under development in the USA, Japan and the UK.
1.4 Characteristics of a Computer
The main characteristics of a computer are:
Speed. Computer executes one instruction at a time. It can add and subtract numbers, compare characters to
detennine matching and copy nurnbers and characters. There is nothing new in these operations. But the
significant point is the computer's speed whjch is measured in clock cycles Le., Hertz (Hz). The time
required by the computer to execute such instruction is from few microseconds to a few nanoseconds.
Accuracy. In addition to the speed, computers are very accul'ate. The circuits in a computer have electronic
parts which do not have wear and tear. Performing their millions of operations per second, these circuits
can run errorless for days together. lf the input data is valid and the program is correct and reliable, then the
computer will always produce an accurate result.
Storage and Retrieval. Both data and program can be stored in a corlputer, ifthey are required for future use.
Wherrever required, both may be quickly retrieved and used by the user for future references.
Repeated Processing Capability. Computer processing involves manipulating the symbols that represent
things required by the user. People have been using character, number and the other symbols for thousands
of years and computer processing simplifies this human task by providing the necessary speed and
accuracy.
Tirne Factor. Response time is greatly reduced while the total time spent in various decision making activities
is reduced to aminimum.
Permanent. In a computerised system a very large amount of data can be stored for future reference. It also
redtices paper work as all the information is stored in the computer itself.
Quick Decision. Problems are handled more easily by using various operations research models, wtrich
enables the user to take quick decision as the time for retrieval of information is very fast.
Secrecy. In a computerised system more secrecy is observed as compared to manual s)'stem. Also chances ot'
leakage of classified information are reduced.
Above all, the computer provides fast access to information and generates reports in no time.
1.5 Hardware and Software
Cornputer data processing involves equipments that can perform the tblloiving function: data preparation;
input to the computer; computation, control and primary storage; secondary storage and output from the
computer. Equipment, which is connected directly to the computer, is termed as "on-line" whereas equipment,
which is used separately and is not connected, is called "ofl'-line".
Soffrvare
Fig. 1.9 Computer hardware and software.
Saraswati lnforrr*atlcs Practices (Xl)
Software is a set of instnictiorts that directs the computer- to orocess informatir-rn. These instructions are
cailed prograrns. R/ithor-rt snftware , the c-.omputer cannot work. A conimonll'used annlogy is that the computer
hardware is the engine, while tire ooftware is the fuel that allows the engine to opelate. Without software the
hardware would be useless. There are trvo types of software available for computer : systern softu,are and
application softwa-re.
Main memorv
Operationai register
Arithmetic
Lcgic Unit
Control Unit
Input / Output
Unit
Similar to input device, outpui devices are also the interface between user and the computer. These
devices take machine coded output results trom the processor and conterl them into a form that can be used
by human beings. In personai computer display screens and printers are the commonly used output devices.
Lar-eer and faster printers, magnetic tapes and l.uge disk units often accept the output of larger systems.
Fig. 1.12 OutPut devices.
1.6.2 CPU
Central processing unit is the heart of any computer system. It consists of
primary
memory unit, arithmetic logic unit and control unit.
tr PROM (Programmable Read Only MemoryJ. A control memory in which stored information can be
altered, but not as easily as in ordinary memory. In some PROMs, the contents may be erased by
prolonged (minute's) application of ultraviolet light, and then rewritten. Once operations to be
performed have been written into a PROM chip, they are pernanent and cannot be altered.
D EPROM (Erasable Programmable Read Only Memory). This type of ROM can be erased and
programmed with the help of special equipment. An EPROM has a window on its top, which if
exposed to ultraviolet light, allows data to be erased. Most EPROM's have a label covering the
window.
D EEPROM (Electrically Erasable Programm.abte ROM). This type of ROM is required to be removed
from its socket to be erased and reprogrammed.
tr [lash EPROM. This is the latest type of ROM, which is becoming very popular. By running a special
program' a manufacturer can make changes to the flash EPROM while it remains in the pC.
A memory unit stores binary information in-groups Row addresses Array of storage cell circuits
of bits called words. Each word is stored in one memory
register. A word in memory is an entity of n bits that
0 00m ffiffiffimffiffiffi
move in and out of thc memory unit. A word of eight bits 1 0m1 mffiEHK$ffi
is sometimes called a byte. A memory is a group of 0's ] MIO EEEfrf;EE
and 1's and may represent a number, an instruction code, 3 mll &88ff1ts#
alphanumeric characters, or any other binary-coded 4 0100+EffiBSrX&
information. RAM Chips is classified as (a) Dynamic
s -4tIXEEnffi
0101
RAM and (b) Static RAM.
Dynamic RAM
6 01104illEsHnffi
7 0111
The storage cell circuits in dynamic RAM chips contain Write/read
a transistor that acts in much the same way as a mechanical circuitry to
on-off light switch and a capacitor that's capable of control data
storing an electric charge. Depending on the switching input/output
O*O-O-Q-
action of the transistor, the capacitors either contains no -Oi*OOi-
charge (0 bits) or hold a charge (1 bit). In figure the right 5555oooo
-r-l*
Since the charge on the capacitor, tends to "leak off', provision is made to
periodically "regenerate" or
refresh the storage charge. A dynamic RAM chip thus provides volatile storage
i.e-,the data stored is lost in
the event of a power failure.
Static BAM
Static RAM chips are also volatile in nature, but as long as they are supplied
with power' they need not require
it takes more transistors and other devices to store
special ."g"r".uto. circuits to retain the stored data. Since
and take up more space for a given storage capaclfy
a bit in a static RAM, these chips are more complicated
applications, while Dynamic RAM's are used
than dynamic RAM's. Static RAM's are thus ur"d i., specialized
to the volatile nature of these storage elements' a
in the primary storage sections of most computers. Due
in larger computer systems.
ba:kup unintemrpted power system (uPS) is often found
Solved Exercises
Qt 0. Define microprocessors.
Ans' Microprocessor is a coinplete processor constructed
on a single chip using VLSI technology.
Intel and Motorola ate two popular Microprcrcessors.
Qll" Distingirish between har<Jware and softwaie.
Ans' Hardware' he different devices artached to the cornputer vrhich
can be touched are called harcware.
Software' Software is a set of instructions that directs the computer
to process information.
Ql2. What is hardware ?
Ans' AII physicai, electrical, eiectronic components of the cornputer
systern are ret-erred as hardware.
QI3" Distinguish between hardrval.e and softlvare.
''{ns' Hardware'' he different rle vices attached to the computeq rvhich can 'be touched, are-called hardware.
software' software is a set of instructions that direets tlie cornputer proccss
to infonnation.That is, the
term software is used to dcscl'ibe progranr sets neecled tc
operate an inforrnation processlng system.
T'hese programs (also called softw'ar e) give life
to the circultry of cc;li;rruier hardware. lt consists of a
seqtlenee of instructions ancl decision r.,,1.. that direct
the cornputer in e,tecuting a tasl<.
-9iven
Evolution of Computers 13
CPU-The Central Processing Unit also calied, as Processor is the main part of computer, which processes
data ol instructions given by user.
CU-Control Unit is the part of CPU, which controls and supervises the task performed by computer.
AlU-Arithmetic Logic Unit is the part of CPU, which performs the arithmetic and logic operations.
Input Units-This is the part of Computer, using this we can feed data or instructions to the computer. For
example, keyboard, mouse e/c.
Output Units-This is the part of Computer, using this we aan take computed results. For example, VDU.
Printers, Plotters etc.
Primary Mernory-The main mernory holds the data and instructions as well as intermediate outputs
during processing. This is temporary in nature and has limited capacity.
Secondary Memory-This is permanent memory of computer. It can store large volume of information
permanently. This is also known as auxiliary memory.
Ql5. Explain the vari6usfunctions of ALU.
Al's. tis unit of computer system performs arithmetical and logical operations on which much of computer
program is based. Special math processors are available on the computer, which supplement the main
arithmetical unit to perform scientific notation. In the arithmetical operations, addition, subtraction,
multiplication, division, exponent and logical operations or comparison are performed.
Ql7. What is the expanded form of RAM ?
Ans. RAM stands for Random Access Mernory.
Ql8. tn which era the Abacus was developed ?
Ans. The Abacus was developed 5000 BC.
Ql9. Give at least three examples of input and output units each.
Ans. Input units are keyboard, mouse, joystick etc. and Output units are printers, plotters and VDU.
Q20. List the main components of the computer system.
Ans. The miin components of computers are{PU, CU, ALU, Primary l{emory Input Devices, Output Devices,
and Secondary Storage.
Q2l. What is RAM ?
Ans. RAM is Random Access memory. RAM chip is made with metal-oxide semiconductor (MOS).
We can select any 1<.rcation on this chip randomly and also we can use it to store directiy, retrieve data and
instructions.
Q22. Give some chardteristics of first generation computer.
Ans. First'genel?ttion computer used vacuum tubes and had a very small memory. It used mercury delay lines
for storage.
Q23. How many parts of primary memory are there ? Write names.
Ans. There are two parts of primary memory-RAM and ROM.
Q24. Define RAM.
Ans. RAM is the pait of primary memory. In this memory any cell can be accessed from any desired random
location. Information can be read from and wriften into in RAM.
Q25. Definetheterm ROM.
Ans. This is the part of primary memory. In this memory information can only be read from. No write operation
can take place in ROM.
14 Saraswati lnformatics practices (Xl)
Q26. What is PROM ?
Ans. PROM is Programmable Read only Memory that can be programmed once.
Q27. What do you mean by EpROM and EEpROM ?
Atts' FPRoM is Erasable Programmable Read only Memory that can be erased as well as reprogralnmed.
And
EEPROM is Electrically Erasable programmable Read Only Memory.
Q28. Name two types of RAM.
Ans. Dynamic RAM and Static RAM.
Q29. Write the types of ROM memory ?
Ans. There are three types of ROM pROM, EPROM, and EEpROM.
-
Q30. Which memory is volatile in nature ?
Ans. RAM is volatile memory.
Q31. Make comparison between Static RAM and Dy,namic RAM.
Ans. Static RAMs take up more space for a given storage capacity than do dynamic RAMs. Static RAMs
are
used in specialized applications while dy^ramic RAMs are used in the primary storage sections
of most
computers' The static RAM is easier to use and has shorter read and write cycles compared
to dynamic
RAM.
Q32. What is the difference between RAM and ROM ?
Non-volatile memory does not require power, once the data are stored. lt is a permanent storage and
comparatively slower than volatile memory.
StaticMemory DynamicMemory
(l) Loses its signal. (,) Does not lose the signal.
(ll) Periodic referencing of (,l) No referencing.
memory is needed.
Review Questions
1. What is computer ?
2. Differentiate between hardware and software.
3. Write down the functional units of a computer.
4. What do you understand by various computer generations and how they differ from each other ?
2.1 lntroduction
the operations
ways. But for
Control Unit
O Input Devices
tr Output Devices
D Memory Devices
O Secondary Storage Devices
2.2.1 lnput Devices
one communicates with a computer system
via the I/o devices interfaced to it. The input
programs and put them into a form devices take data and
the computer can process. The most common
and a mousu and others arepunched_card, input devices are a keyboard
magnetic_tape readers, etc.
The input devices feed the necessary aia
into the machine. In most general-purpose computers,
constitute the program ,urt u" ,"uo into the
the machine along with alt tire iata to be
::tfflfffJlat used in the
(16)
Keyboard
The keyboard is the most cortmon and simplest input device. It allows you to communicate with the computer.
It consists of four main areas: the function keys, the typewriter keys, the numeric keypad, and special-purpose
kcys. The central area of the keyboard contains the standard typing keys (i.e. A, B, C, D, etc") and the spacebar.
The standard keys consist ofletters, numbers, and special characters such as the semicolon and the dollar sign.
Fig.2.2 shows a sample keyboard.
Function keys Numeric pad keys
Numeric
Mouse
The mouse is an input device that is used in addition to the keyboard. It is a hand-
held device that controls a pointer on the screen. When you move the mouse around
the desktop, ihe rubber-coated ball on the bottom of the mouse moves.
'Ihe ball's
movement is translated into signals that tell the computer how to move the screen
pointer. On top of the mouse are two buttons that are used to make selections from
items on the screen.
Fig. 2.3 A typical mouse.
Optical Character Reader (OCR)
It can detect characters A, B, C, D and so on by shape. It can read up to 750 documents per minute or 1500
characters/sec. OCR is quite costly because the memory
requirements are very high. OCR also employs a set of printing
characters with standard fonts that can be read by both human ew{, *{ sx JW- g_ t1
and machine readers. The machine readers are done by light
w*p exg,?{,v &* VU x.
sianning technique in which each character is illuminated by
a light source and the reflected images of the characters are
#b* XWSq&Va t* *(
analyzed in term of light dark pattem produced. Keyboard vfii ; ?t** &* *w t{f,
devices are used to give the required print quality. OCR has ***
the potential of reading even handwritten documents
straightway.
Fig. 2.4 Optical charactcrs.
18 Saraswati lnformatics practices (Xl)
The optical character readers have slightly irregular typeface as shown in the Fig. 2.4.
They can read the
characters printed by computer printers, cash registers, adding machines and typewriters.
Some readers can
also read handwritten documents. Fig. 2.3 shows some handwritten characters that
can be read by recognition
devices, most optical character readers can be used to sort out lbrms as well as to read
data into computer
storage.
r6ffi
Magnetic Inks
rJlury Hutrber
commandstothecomputer.Manyjoysticksalsohaveadditionalbuttons
for sending different commands.
Fig.2.6 Joystick.
Light Pen
Light Pen is used as a pointing device. A person can point the pen and
p"ifor. drawing of a lini or curve on the screen. It may be noted that light
pen will
pen does not emit light. The light sensitive diode at the tip of the
sense the light coming from the screen. The light pen is also
useful for
graphics work. For example, the user at the computer-aided design
(CAD)
terminal can "draw" directly on the screen with the pen'
Fig.2.7 Ll.;ightPen.
Touch Screen
screen is a computer screen, or visual display unit, which responds
to the touch of a finger or other
A touch
or icons' The user touches the
pointer. Usually u numblr of choices are displayed on the screen as pictures,
that choice' The touch screen
icon that represents their choice, and the computer displays information about
screen' which has been touched'
works by sending a signal to the computer. This gives the location on the
malis, airports, and amusement
Using a iouch screen is quick and simpG. The Touch screen is used in shopping
parks.
Voice/Speech lnPut
Scanner
Scanners provide
Internet pages or
page scanners, an
full color graphics.
per inch (DPI) that the scanner reads' The
The resolution of a scanner is measured by the number of dots
sulting scan
in mind co
olution, the
when your
to be stored. And, if you'll be printing, it makes no sense at all to scan a large image at 500-600 DPI'
20
Saraswati I nforrnatics practices
printer will only handle 300 DPI. Aciditionally,
if you are going to place ttre image on a rveb page, a 200 DpI image
will be more than adequate.
Hand Scanners
SmailCards
'fhe cards are being used to some e):rent in the United States for example by the US Nav.v, and for
-
purchasing procedures, they incorporate a keypad and a display unit along rvith memory and processing
capabilities. Other manufacturers are already talking about a "supersmaft card" that rvould be a "key" that
usel's n'lust ernplol, to gain access to speciai computer systerns. Even today, we would be able to use our
"unintelligent" bank car:C with its rnagnetically encoded strip to pay for gasoline and groceries at some service
stations and superrnarkets, by electronicalll, transferring the funds. The purchase amount is autornatically
deducted frorn your bank balance without any fufther action fi'om your end.
Bar Code Readers
Bar Code Readers are electronic readers (similar to pens in shapes) that read the values or quantities printed on
the products and put in the form ofveftical bars. The bars are ou groceries, cosmetics, paperback novels and
so on. Bar codes are recorded on the products by the manufacturers and usually, carry the inventory stock
number (also called the product number). The ccding scheme called, lJniversal Product Code for recording the
data, is based on the rvidth of the bars and the spaces between thern.
-
Begin/end code
NUTRACHEW
0 1
cRa.xooL.a.eRAs
llll
IVlanufacturers idenfi fi cation numbet
Fig. 2.1I A bar code machine sucir as Universal Product Code used in supermarket.
Trvo types ofinput scanning devices are useC to read the bar codes. The first is a hand-held scannerthat
the clerk passes over the tag rvith the bar code. The wand has a scanning device that analyses the light and dark
bars for width and spacing, translating this ciata into electrical signals for the computer. The second is found
rtrost often in.the supermarkets and is built into the device at the top of the counter along with a computerized
cash register. Thc firnction of the scanning device is sinrilar to the hand-held wand; however, in many cases, the
light source of the former may be a laset'.
Bar code readers have proved to be very valuable as data entry devices tbr two reasons :
1. Thepriceandproductinventorynunrbeisdonotneediobekeyedin,eliminatinganychancesformany
feeding errors (quantity of items, however. is keyed in). The sales data and inventory status stored on
flle are kept on a current status.
2. A complete history can be created and stored for each bar coded item for delivery services.This means
that the parcels can be traced.
[{owever, tvhen you are checl<ing out at the supermarket, keep an eye on the computerised price and item
description display on the register. As we mentioned earlier, the product nutnbers are recorded in the bar codes
on tlre items you buy but the corresponding price files must be updated at the supermarket. If someone forgets
to enter Today's Speciat50 Percent Reduction in Cat Food Prices in the store's computer, you would end up
paying the old price.
Biometric Sensor
This is the security device that verifies personal characteristics such as fingerprints, hand size, or signatures.A
t iometric sensor, fingerprint sensor to be specific, also known as the fingerprint reader, is a fingerprint image
(ilpture elevice, the verl frcnt end of the biometric fingerprint identification/verification module. The fingerprint
22 Saraswati Informatics Practices (Xl)
sensor captures the fingerprint images, matches the uniqueness of each print read by the sensor and compares
it to the one stored in its module or local system database. Types of fingerprint sensors are Static Capacitive
Type 1, Static Capacitive Type 2, Dynamic Capacitive, Optic Reflexive, Optic Transmissive with Fiber Optic
Plate, Acoustic (Ultrasound), Pressure Sensitive, Thermal Line, and Capacitive and Optical Line. All the types
of the fingerprint sensors are generally known as optical, semiconductor, and ultrasound sensors. Among all
the senscrs, semiconductor sensors are considered to be low cost, optical sensors are considered to have a
high degree af stability and reliability, while ulfrasound sensors are very precise and fraud-free though expensive
toimplement.
It is true that a lot ofthe technical specifications for a fingerprint sensor are very configuration-dependent,
as well as application-specitic. For example, False Rejection Rate and False Acceptance Rate, two of the most
important fingerprint security benchmarks, vary according to different applications and configurations.
DigitalCamera
Digital cameras are very much like the still more familiar 35mm film cameras. Both contain a lens, an aperture, and
a shutter. The lens brings light from the scene inio focus inside the camera so it can expose an image. The
aperture is a hole that can be made smaller or larger to control the amount of light entering the camera. The
shutter is a device that can be opened or closed to conffol the length of time the light enters.
andEGA.
Fig.2.l3 Monitor
Printer
Printers are the primary output devices used to prepare permanent documents. Along
with the computer
to tell us what we have sent in as an input and what it has
screen, a printer serves as a midium for the compuier
is that the printer generates a pemanent hard copy of our
done in ."rponr" to the same. The only difference
work on paper.
Classifications of Printers :
at a time'
tr Character printers (dot matrix and daisy wheel) that print one character
tr Line printers that print whole line at a time'
O page printers (also catted image orinters, e.g. laser printer) that print whole page at a time'
tr Impact printing
D Non-Iinpact Pnnting
lmpact Printers
An impact printer makes
A printer in which printing is the result of mechanically striking the printing medium.
may produced by a print hammer character'
contact with the pape. to pioduce an image/character. The impact be
or by print hammer hitting paper and ribbon
like that of a typewriter key striking a ribbon against the paper a
against a character. For example, dot matrix, daisy wheel, line printers'
24
DaisyWheel Printer
Daisy wheel printers are srower than dot matrix printers,
but produce high
quality output. This high quatity outpur is oiten calicd
Gtter quatly
printing because it is suitabie for businiss letters and
memos.
Fig. 2.14 A dot matli5printer
Line Printer
tr Ink-jet printers
D Laser printers
tr Thermal printers
lnk-jet Printer
It is a technique of spraying droplets of ink at paper
to form the
Ink-jet printer (a
non-impact) creates ar., i-age directly on paper
through as many as 64 tiny nozzles. It provid-es
a print qualiiy of
per inch.
Plotters
A plotter is a specialized output device designed to produce high quality
graphics in a variety of colours. Pictorial output of data, which could
range from simple statistical histograms, pie charts, advertising kiosks,
etc. to detailed isometric drawings, could be generated using plotters'
Although other printers can be used for simple charts, yet plotters produce
high quality output that is unmatched. There are two basic types of plotters
those that use pens and those that do not. Drum plotters and flatbed
plotters use pens. Elecffostatic plotters do not use the same.
Fig.2.18 A typical plotter.
1. RAM chips are located on the motherboard electrical signals have to travel from
so the distance the
the CpU to RAM or in the opposite direction is much shorter compared to the distance between the
26
CPU anC secondaly storage devices. The shorter the distance, ttre faster the processing.
2' AIso working with the secondary siorage invoives mechanical operations
like spinning.
Cost' Secondary storage is cheaper than RAM in terms of cost per unit of data.
The amount of data a disk can
hold is called disk capacity. Disk capacity, Iike rnemory, is measured in Kilc,
By'tes (KB), Mega Bytes (MB) and
GigaBytes(GB).
The most corlmon storage devices are floppy disk, hard disk. tape drives,
cD-RoM, DVD and zlp dive.
All the storage devices use sinrilar techniques for reading
and writing data, because all use the same medium.
The surface of diskettes, hard disks and magnetic tapes are all coatel with
a rrragnetically sensitive material
(usually iron oxide), which reacts to a magnetic field.
2.3.2 Floppi'Disk
Floppy C transport data
from one
ivhich is ff1*,:i:::';
within a square plastic of cardboard jacket. The jacket gives handling
protection to the disk surface.
Floppy disks are typically 3.5, 5.25,or g inches in cliameter. Th"y .
come either in single or doubie density versions. They store data
either on one or tioth surfaces of a diskette.
Hard disks and floppy disks have a top surface and a bottom surface. Information is generally stored on
both surfaces. Concentric circles divide each side of the disk surface into tracks . The size and number of tracks
is machine dependent; this is determined by the blend of installed hardware and software. High density floppy
disks have more tracks than low density floppy disks.
The read/write process in the floppy disk is done using through floppy disk drive. Generally, floppy disk
drives in computers are named as A:, B drive.
Sector 0
Sector I
Sedor N
L
Fig.2.20 Tfacks and sectors inside a disk.
The portion of a single track in a single sector is called a block. The size of the block is also machine
dependent.
Block 0
Block 1
4+
Read -Wfie
t i r-' /, ,f ' AnrVHead
ik - j',;
!.\'----'{.,.'
r \ \- -' / ,'
Block 3 -
(c) (d)
tr they have a limited capacity (graphics files often don't fit in a disk);
tr they are relatively slow;
tr they are less reliable than hard disks so proper care should be taken to prevent loss of data.
It is important to take proper care of your disks to minimise the danger of losing data.
2.3.3 Hard Disk
A hard disk is physically composed of a series of flat, magnetically coated
platters stacked on a spindle. The spindle turns while the heads move
between the platters. After that in a cyclic movement data becomes reading/
writing onto the platters.
A disk is divided into tracks, cylinders, and sectors. A track is that portion of a disk which passes under
a single stationary head during a disk rotation, a ring 1 bit
wide. A cylinder is comprised of the set of tracks described
by all the heads (on separate platters) at a single seek
position. Each cylinder is equidistant from the centre ofthe
disk. A track is divided into segments of sectors, which is
the basic unit of storage.
The hard disk is a permanent fixture containing one or
more circular metallic disks that are used to store data files
and software programs. A hard disk can store more
information than a floppy disk.
A typical 10.5 inch reel of magnetic tape is 2,400 feet long and is able to write 800, 1600 or 6250 characters
of this length. The magnetic advantages of magnetic tapes are : unlimited storage capacity, high data density,
low cost, rapid ffansfer rate, easy ofhandling, portability, etc.
2.3.5 CD-ROM (Compact-Disk Read Only Memory) Disks
Computer storage device developed from the
technology of the audio compact disc. It consists of a
plastic-coated metal disk, on which binary digital
information is etched in the form of mictoscopic pits.
This can then be read optically by passing a laser beam
over the disk. CD-ROMs typically hold about 650
megabytes of data, and are used in distributing large
amounts of text, graphics, audio, and video, such as
encyclopaedias, catalogues, technical manuals and
games.
Big.2.2fi Aqpical CD'drive and CD'ROM.
Standard CD-ROMs cannot have information written onto them by computer, but must be manufactured
from a master, although recordable CDs, calted CD-R disks, have been developed for use as computer disks. A
compact disc, CD-RW, that can be overwritten repeatedly
by a computer has also been developed. The compact disc,
Focused beam
with its enorrnous storage capability, may eventually replace
i
the magnetic disk as the most common form of backing
store for computers.
The technology is being developed rapidly. A
standard CD-ROM disk spins at between 240-1170 rpm
(rotations per minute), but faster disks have been
introduced which speed up data retrieval to many times
the standard sp-eed, Research is being conducted into high-
density CDs capable of storing many gigabytes of data,
made possible by using multiple layers on the surface of
the disk, and by using double-sided disks. The first
commercial examples of this research include DVD (Digital
\trsatile Disks) players and DVD-ROM cornputer disks
launchedin 1997.
The advantages of a
Fig.2.28 A Zipdive.
Zip drive are :
D portable
D easy to use
D fast.
Zip disks come with the capacity of 100 M or 25 M
and you can double it using a compression software
STACKER (althoughlomega doesn'trecommend like
it). The avlrage seektime is 29 milliseconds for l00Mb
and 16 milliseconds for 25 Mb disks. disks
D GIGABYTE. A collection of 1024 MB makes a GIGABYTE (GB). Nowadays the Hard disks are coming
in a capacity of gigabyies such as lOGB, 20 Gts, 40 GB, 80 GB etc.
Solved Exercises
on the paper, Using this feature, a dot-matrix can e!r'en draw pictures, graphics etc,
Ans. MICR stands for Magnetic Ink Character Reader. It is input/output device mostly used for reading
cheques in the bank.
Q2l. What is light pen ?
,Lns. Light penls used as a pointing device. A person can point the pen and perform
drawing of a line ol curve
on the screen.
Q22. Compare primary and secondary memory.
are permanent
Ans. The primary memory is volatile and has timited capacity whereas secondary memory devices
and can store large volume of data.
Q23. Def,ure:
(a) cylinder (b) track (c) block
Ans. Track. The number of invisible concentric circles called as tracks.
Cylinder. In the Hard Disk, which consists number of disk. Here the set of corresponding tracks in allthe
surfaces is called a cYlinder.
Block. Btock is the group of recorded on magnetic tape'
Q24. Define optical disk.
,lns. tn Opticat disks, information is stored in pits that are prepared by using a high-power laser beam'
Q25. Which disk is created using laser beam ?
Ans. CD-ROM is created using laser beam.
Q26. How many bYtes in a MegabYte ?
Ans. 104857 6 (1024x1024)b1tes are equalto one Megaby'te (MB)'
Q27. What is CD-ROM ?
disk, creating flat and
Ans. A CD-ROM disk is created by using a laser beam, which alters the surface of the
bumpy areas called,,pits" on the bottom of the disk. These areas represented data.
A CD-ROM drive uses
typical CD-ROM disk is 5'25
a lasli that projects a tiny beam of light onto the disk to read the data. A
inches in diameter and can store 650MB of data, the equivalent of 147 floppy
disks.
Review Questions
Compuler Softwore
3.1 lntroduction
A computer system has two parts hardware anC the software. The hardware is useless until we do not have
-
the associated software. The software is necessary to run the computer. There are different types ofsoftware
available. We will discuss differenttypes of software and languages in this chapter.
3.3Types of Software
There are two types of software available for computer .
tr System software
D Application software.
3.4 Software
What is Software?
Software is a set of instructions that directs the computer to process information. These instructions are called
programs. Without software, the computer cannot work. A commonly used analogy is that the computer
hardware is the engine, while the software is the fuel that allows the engine to operate. Without software the
hardware would be useless. There are two types of software available for computer - system software and
application software.
3.4.1 System Software
System software program coordinates the operation of the various hardware components of the computer. The
system software or operating system program helps the user to actually operate the computer system. This is
an interface between the user and the computer.
The operating system oversees the processing ofthe application programs and all input and output ofthe
system. Without the operating system, you can not use the applications software programs to operate. The
operating system controls computer system resources and coordinates the flow of data to and from the
microprocessor and to and from input and output devices such as the keyboard and the monitor.
System software is usually provided by the computer manufacturer. The various types of computer require
different types of system software programs in order to operate. Some of the most popular are DOS, Macintosh
operating system, OS/2, Windows 95, and UNIX.
The system software consists those programs that control and support the computer system and its
data processing applications. It includes the following :
(3s)
D Operating System tr Language Translators
A broad spectrum of the
above software isusually available from the manufacturer, but some software
available from software concerns. These generally charge extra for software but
are also
some manufacturers
furnish software without extra cost for those who purchase-or lease their equipment.
We willnow describe each ofthe aforesaid software in detail :
3.4.1.1 Operating System (OS)
Considerable tirne is ordinarily wasted in computer setup supervised by the
operator. During compilation/
assembly run time required to input the magnetic tape consisting of(the main prograo,
uni subroutines,
etc') ts substantial and would naturally be pinching. Likewise several application program (viz.,
s inventory
control, A/c receivables etc.) would be read into the CPIJ in turn every day or so. Ttris
too, wastes the working
time of the computer. Thus time reduction can be had by maintaining all the programs (including
utility
programs,assemblers,compiler, etc.)inthebackingstoragewhichmaybeofferrite*r.or,ror.commonly,
of hard disk but inter linked with main memory. The required p.ogru, can berecalled
into the CpU far
ntore quickly than inordinary systems where computer is especialiy setup for
each application run
or assembly compilation run etc.,saving considerable time on setups.
Operating system is an organized collection or integrated set of specialized programs
that controls the
overall operations of a computer. It helps the computer to supervise and manage
iti resources. operating
system calls ttre application program whenever needed, translaies the special
,.*i..
programs and managei
data needed to produce the output as desired by users.
3.4.1 .2 Language Translator
Assembler' Assernbler is used to conveft the program written in assembly language
into machine language.
Compiler. compiler translates a source program that is usually written in a high liveilanguage
by a programmer
intomachinelanguage.Thecompileriscapableofreplacingsinglesource programstatementwithaseriesof
machine-language instructions or with a subroutine. For iactr trlgtr level
language the machine requires a
separate compiler.
Interpreter. Interpreter translates each source program statement into a sequence
ofmachine instructions and
then executes these machine instructions before translating the next source language
statement. Interpreter is
also unique for each high level language, like computer, Basically the
function ortie complter and interpreter
are the same, the only difference is that compiler provides u r.purut.
object program but the interpreter does
not' At the time df using interpreter each and everytime, the source program
is needed. Another difference is
that interpreter translates the source program line wise i. e., it will not exicute
the next line unless the first one
has no error.
In this editor
(a) Special Text Editor. This editor is used to design or write a program in interactive mode.
userjust type its requirement and the program code is generated'
Text Editor. This editor is used to type only text matter. The text may be stored
for future reference'
O) Notepad are the popular
Also, the text may be modified or changed. Word processing, MS-Word and
text editors.
,,t' 4
L(ri. li n"/: \I/j !
i.:.;
-:l
C-i
Sales-D-els-&L]{Pff -?[!]-
Sales DataforYear200l
s000
-3 auno
$ soco
&20fia
u, '"'-
fir 1il'!fi
fr
Jen Feb l,iiar A]rr Tc(ai
Q alac
$ales Person
In11.1it.gn
.1l1.pn
T,,v1
riri'lrtl
Twl 1 12 prr'
'l+ ,,
T*r1 1-l-JE pir .i :?11..
Iur11
I l.l I -.1 ,t. prn6 '1
2/5159 0:1S
.l215193ti:l9Flr4
Pld 1.318.$ e 3{:; ?t,273
Il11-I5.pm5 ?.325.558 97z. 1[2_teE
I ll 1 ''t F. orn6 13/519$ 8:'19 PM 2.2fr6.729 s7Z \Z,fiAB ..1
@ Disk Fragmentation. You can use Disk Defragmenter to reaftange files and unused space on your
hard disk so that programs run faster.
I You can also start Disk Defragmenter by clicking Start, pointing to Programs, pointing to
Accessories, pointing to System Tools, and then clicking Disk Defragmenter.
..*;
}/-si 1i l!,)b,
srsSix(g&ith$iii&. ,rt, :a! l-: ai
Fig. 3.9 Norton AntiVirus first screen. ip6.arMr** d.er tqT@J (t rr J k <.r.rz
2 Select Scan All Hard Disks for Viruses from the list and
click Run Scan Now. You may also define a new scan
task to scan only selected hard drives by clicking Create
New Scan and following the instructions in the Scan
Task wizar-d. The Norton AntiVirus will continue to scan
all the drives including files and folder as shown in the
Fig.3.il.
J If Norton AntiVirus alert appears on the screen. it gives
information about the virus. There are two options
available to eliminate a virus : automatic and manual.
A
+. If you choose manually, the Probleurs Found screen
will appear which gives information about the viruses
fourrd. Now, you can :
Repair. It found the virus and repairs the
infected file.
Delete. It deletes both the virus and the infected
file.
Exclude. If you choose this option and the virus
is at work, the virus will not be detected.
Quarantine. It just freeze the virus infected file
but does not remove it.
Stop. It stops the current operation to prevent
you from using an infected file.
5. After repairing the virus, you will get the
scan results as shown in Fig. 3.12.
.*i
, lfelce*tre !E: l-iveltgdat*
Li.slj0d;1-. [h+.tr ltr *!,J3let idt]-t!n ilrr3*rtr:l+Ct;;i! ;r.(]
cea iBrf!'!i:ih uliera lr'G{ rarri :.s rri:,lsii
. you can also start Disk Cleanup by clicking Start, pointing to Programs. pointing ter Acetssories,
pointing to System Tools, and then clicking Disk Cleanup.
44 sar
The follov;ing Fig. 3. 1 3 u,ill appezr :
0.0il.dB ..
-bot.ipp
htlp:lius il.yirng com/us.1,irng ca-. JPEG lnrage 8K6 '
tps htip//us i1.yimg.eom,/us yimg.co JPEG lmage 3KB ,
.ETf;
l!:; C.fllie:E
Solved Exercises
Ans. A computer virus is a computer program that can inject other computer programs by modif,ing them in
such a way as to includc a copy of it. A virus not only copies itseif but also makes the computer system
behave abnormally.
11. Name the types of software with example for each,
Ans. There are two types of software-system software and application software. Examples are-Translators
48
Review Questions
i*-
Chapter - 4
Operoling System
4.1 lntroduction
An Operating System is a system softrvare which may be viewed as an organised collectiotl of software
consisting ofprocedures for operating a computer and providing an environment for execution ofprograms. [t
is a class of programs which manages the resources of the computer, processes cornmands, and controls
program execution. As the foundation of all computer operations, it is the most complex program executed on
the computer, yet must also be the most reliable.
There are many important reasons for studying the operating systems. Some of them are :
D User interacts with the computer through operating system in order to accomplish his task since it is
his primary interface with a computer.
O It helps users to understand the inner functions of a computer very closely.
tr Many concepts and techniques found in operating system have general applicability in other
applications.
(4e)
From the above figure, it is clear that operating system directly controls computer lrardware resources.
olher programs rely on facilities provided by the operating system to gain access to computer system resources.
An operating system plays a role something like a symphony conductor. When the score calls for the
violins to play, the conductor cues the violins; when the score says the cellos should play more softly, the
tympani should stop, or the entire orchestra should pick up the tempo, the conductor so instructs the musicians.
The players in the orchestra and their instruments represent the hardware, The experience and skill
of the
conductor represent the operating system. The score represents gn application progru*.
When an application program is replaced by another for instance, un u..orrling program is put
- aside
and replaced with a word processor - the sante hardware carries out the instructions oittre same operating
system, A different program, a different purpose, perhaps, but the elements are the same.
O Memory Mauagement
D Processor Management
tr Device Management
O InformatjonManagement
O Keep track of the status of each memory location whether is allocated or free.
D Selecting the allocation policy for the momory.
O Select the allocation technique to determine the specific locations to be allocated and to update
the
allocation information
al Handling the delocalization ofmemory.
The main advantage of this allocation is it is simple among all the allocations atid does not require any
expertise to understand or use the system. The main disadvantage is the poor utilization of main memory and
poor utilization ofthe processor.
The first entry gives the size ofpanition and the next entry gives
the starting location ofeach partition. The
last entry gives the status of each partition.
time are generally of dift'erent lengths. As
the s of various sizes tend to appear between
suc
. The main advantage
utilization
of static partition allocation is that it allows multiprogramming and allows efficient
of the processor and input or output devices. It also requires no special costly
hardware.
The main disadvantage is the fragmentation, which dependr on th. typical job
,"qrln"". and algorithms
used and also even if memory is not fragtnented; the singie free may
not be large enoughior a partition. This oS
needs more memory as compared to single contiguous allocation.
4.4.1.3 Compaction
4.4.1.6 Swapping
In multiprogramming environment, when the system is allocated to the
next user, the current contents of user
memory were written out to a backing store and the contents of the
next user was read in. This is called
Swapping as shown in Fig. 4. 6. The backing stores
commonly fast drum or disk.
are
The main advantage of paged memory It{onitor
management is that this scheme eliminates Sw
fragmentation. It increases the degree of User Space lUSR't
multiprogramming, which results in the increased
memory and processor utilization. Swapin lffiFir
Main Memory Backing Store
The disadvantages of this teclinique are that tlre hardware required to nlap the page address generally
increases the cost ofthe systeur and slows dorvn ihe processor. Intemal ffagmentation orpage breakage does
occur.
The technique we have studied so far is useless to run a job untilthere was sufficient available main memory lo
load its entire address spaee. The solution of this problem is to use extremely large memory but it is economically
irot feasible. The second apprcach is to use the operating systeln to produce the illusion of extremely iarge
txemory. Since tlris rnerriory is merel_y an iliusion, it is called virtual memory. There are tlvo virtual memory
methods :
Here the sum of allthe address spaces of the jobs beingmultiprograrnming may exceed the size of physical
memory. This is achieyed by rernoving the requirenrent that the entire job should be available in main memory
at one time, Instead only the needed portions have to be loaded as and when required.
For example, ifthree jobs are loaded in memory and two blocks are free: when a fourth job with a requirement
of 4 btocks comes what to do ? The simplc solution is loaditg the pages in the availabie blocks. As and u'hen
it refers to the instluction which is nr;t currently avaiiable in the main memory the required page rnust be
brought in. When there is a demand to load the page in memory the operating system decides which page to
keepinmemory i.e,theOsisresponsibletoperformnecessaryaction.ThisschemeiscailedDemandpage
mernory managernent. When a.;ob is initially scheduled for execution, only its first page is loaded. AII the other
pages needed b;r the job are subsequently loaded on dernand. This ensures that an unnecessary page is not
loadeci,
The pages, which are loaded on the demand, are present on the secondary storage devices. When a page
is needed in main men)ory, it is read frorn the secondary storage device. Once mernory is filled with pages, it is
possible to load another page only' by removing one page presently in memory. The replaced page is copied
back onto the secondary storage device before the new page is loaded. How do we decide which page is
removed first ? There are so many page removal techniques available like First - In - F-irst- Out, Lease Recently
Used elc.
As we see there is a movement of pages between the main memory and the secondary storage devices. The
phenomenori of excessively moving pages back and forth between memory and secondary; storage devices is
called Thrashing.
The main advantages of this technique are that there large virlual memory is available. The memory is used
efficiently. 'l'he disadvantages ofthis technique are that the processor overhead for handling interrupts and to
maintain number of tables and thrashing.
D Using special mechanisms has to keep track of the status of all the devices.
tr When requests come , has to decide on policy to determine who gets a device, when and how long;
C Assigning a device to jobs;
O When the job is over, deallocating the device and changing the status information.
The module that keep-the track of the status of devices is called l/O Traffic Controller.
All modules associated with the operation of a single device are called I/O device handlers. All the L()
clevices can be classified into any one of the followingthree categories:
O dedicated
D shared
U vlftual
A dedicated device is allocated to a single job for the job's entire duration. For example, consider the
output device printer. This de.vice by nature falls in this category. There may
be a situation where several users
want to use the printer at the same time. If it is not dedicated, imagine ihe output procluce
by the printer.
B,eqause of this reason the printer is a dedicated device.
The devices like disks, drums ancl other direct access devices are shared devices.
Because these devices
can be shared by several jobs at a time, Many jobs can be read from the disk
at a time. These devices are
efficient but complicate to manage. For example, if two jobs request a read from disk, some
mechanism rnust be
employed to determine which r.equest should be handled first.
Some devices, can be convefted fi'om dedicated devices to the shared devices like
card reader. The
technique' which is converting the dedicated device to shared device, is called spooling.
For example, a
spoolitig program can read and copy all card iip on to a disk at high speed. Later when p.-o".r,
u tries to read
the card reader, the spooling program intercepts the request anJ converts it
to read from the disk. Here a
dedicated device is converted to a shared device, changing card reader into many,.virtual,,card
readers.
The device management depends on the nature ofthe input and output device
and the request arrives,
manages all devices and utilize it in efficient way with the help ofthe program
modules I/o traffic controller, I/
O device handlers and I/O schedulers.
. In the mod-ern computers most of the jobs depend upon the disk for loading input and output files, it is
impoftant that disks service be as fast as possible- rne cis can improve
on the average disk service time by
scheduling the request for the disk access. There are sufficient aigorithms
available to achieve the above
requirement. l'hese are ;
O First-Cum-first-served(FCFS)
O Shortest-seek-time-first(SSTF)
D SCAN
4.4.2.1 First-Cu m-First-served
FCFS is the simplest form of disk scheduling. In this scheduling the job
comes first will served first. with an
example, if the request for the tracks comes jn the following order :
50 80 190 57 106 08 ll5 p. and 65
Let us assume that the readlwrite head is initially at track 50, it will move
from 50 to g0, g0 to I 90, 190 to 57,
then to 106, 08, 115,82 at last at 65. The total head movement is
5g3 tracks.
a
L
o
-o
z
(-)
Fig.4.7 FCFS.
Operating Systen'l 55
The rnain disadvantage of this technique is that it increases the average service time with increased head
movement. As you see the head move from track I 06 to 08 then back to 1 1 5.
This scheduling improve the average disk service. Butthis may cause starvation of some requests.
190
\
\
ll5 \
C) 106
\
tr \
fa \
vzo 80
! 65
F F57
50
Fig.4.8 SSTF,
4.4.2.3 SCAN
the read/write
SCAN is evolved because the dynamic nature of the request queues. In this scheduling method
servicing requests as it reaches each track,
head starts at one end ofthe disk, and moves towards the other end,
direction of head movement is reversed and
until it reaches the other end of the track. At the other end, the
to end. In addition to head's last position,
servicing continues. The head continuously scans the disk from end
and reaches
we need to know its direction of movement. If the head was moving towards 0 it services 08-first
disk, servicing the requests 57 , 65,
track 0. At track 0 the head would reverse and move to the other end of the
g0, g2, 106, i l5 and 195 as shown in Fig.4.9. The SCAN algorithm is also called the elevator algorithm'
1m
\
\
115 \
L
C)
\
-o \
z \
.5t
'o
cS
L
F
\
\
Fig.4.9 SCAN.
4.4.3 lnformation Management
This part of the operating system manases the information. Before going
in detail of the information, let us
understand the concepts of file' File nranagement aspects of operiting
system is one that deals with the
ixallagement of data and program, which resides on seconddry storage
device. File is a collection of related
information defined by its user. It is named and referred to by its naml.
The file s)'stem is the most vlsible part olthe operating system. For
many computer users the interface,
structure and reliability of the file systeru largely determines the convenience
and usabiiity of the operating
system.
Files are normally organized on the directories for easy access. Therefore,
rte wili also look at different
directory structures. Since files are shared among multiple users it must be protected
against unauthorized
users, so at the end we rvill touch upon file protection issue.
4.4.3.1 Directories
A directory is a file, which keeps track of all other files. A single directory can contajn
a list of all files in a
system' Flat directories are those directories in which the root diiectory
contains all system files and there is no
othet sub-directory. When hierarchical directories are used, the colleciion
of all directory and sub-directory
entries defines the totality ofthe system Iiles.
(N Creating a file. For creating a file firstly we have to search for the free space in the file system i. e. on the
,
storage device. lf the space is available then we make the entry
for new rite. the directory entry stores the
name of the file and its location on the file system and all other
information related to that file.
Operating System 57
(ii) Writing a file. For writing in a file, a system should know the name of the file and the contents, which
should be written on the file. Given the narne of the file, the system is searching the directory to find the
location ofthe file. The directory should contain a pointer to the current end ofthe file. Using this pointer,
the address of the next block can be computed and the infonnation can be written.
(lii) Reading from the file. To read a file, again we need the name ofthe file frorn which the infonnation has to
be read. A request should be made to the systern call with the name ofthe file and stafting address of the
mrin rnemory where the read contents should be put in. To achieve this, the directory is searched for the
valid file name. As soon as it finds the name, it has to get the contents from the secondary storage device
and transfer into the main memory.
(lv) Delete a file. lWhen the command delete is given, the directory is searched for the named file. If found,
release all file space, so that it can be reused by the other files and directory entry is invalidated.
Information management is nothing but the management of all these files and file directories usittg the
information llom the device management part of the operating system.
4.4.4File Protection
ln multi-user environment the file protection is necessary. Because a file is shared by the multiple users. The
protection mechanism must provide controlled access by restricting the types of files, which can be made. The
access is permitted depending upon several factors. The several mechanisms to support the protection are :
4.4.4.1Passwords i
In this methods the password is associated with each file. Just as a password is required to access a computer
system, access to each file will be controlled by a password. The rnain disadvantage of this method is that a
separate password is associated with a different file, the numbers of passwords that need to be remembered are
quite large, makingthe sch'eme impractical.
4.4.4.2Access List
The second approach is to make access dependent on the identity ofthe user. Various users may need different
types of access to a file or directory. An access list can be associated with each file and directory, specifying the
user name and the types of access allowed for each user. When a user request access to a particular file, the
operating system checks the access list associated with each file. Ifthat user is listed for the reqttested access,
the access is allowed. Otherwise, a protection violation occurs and the user job is denied access to the file.
(i) Process hierarchies. Operating system needs some way to create and kill processes. When a process is
created, it creates another process(es) u,hich in tum creates some more process(es) and so on, thus
process hierarchy or process tree.
(ii) Process states. The lifetime of a process can be divided into several stages as states each with certain
characteristics that describe the process. It means that as a process starts executing, it goes through one
state to another state. Each process may be in one of the following states :
Running
tr Process number. Each process is identified by its process number, called process ID.
D Prioritlr
tr Process state. Each process may be an1 ol'these state; new, ready, running, suspendecl and
terminated.
O Prograrn counter. It indicates the address ofthe next instruction to be execLrted for this process.
4.5.3 Process Scheduling
Scheduling is a fundamental operating svstelr function. All computer resources are scheduled
before use"
Since CPU is one of the prirnat'y cornputer resources, its scheduling is central to operating
system desien.
Operating System 59
Scheduling ref-ers to a set of policies and nrechanisms suppofted by operating system that confi'ols the
order in which the work to be done is completed. A scheduler is an operating system program that selects the
next job to be admitted for execution. The main objective of scheduling is to increase CPU utilization and higJrer
throughput. CPU scheduling is the basis of operating system, which supports multiprogramming concepts. By
having a number of programs in computer memory at the same time, the CPU may be shared among them. This
mechanistn irnproves the overall efficiency of the computer system by getting more work done in less time.
4.5.4 Types of Scheduler
There are three types of schedulers: long terrn, medium term and shoft term schedulers in terms of its objectives,
operating environment and relationship to other schedulers in a complex operating system environment.
(i) Long term scheduler. Sometimes it is also jobs scheduling. This determines which job shallbe admitted
for irnmediate processing.
There are always more processes than it can be executed by CPU as in Batch Operating System.
These processes are kept in large storage devices like disk for laterprocessing. The long-term scheduler
selects processes from this pool and loads thern into memory. In memory these processes belong to a
ready queue.
End of
aprogram
Suspended and
swapped-out queue
Long tcrm
Sched
Job
Process CPUTime
Pl 30
P26
If these processes arrive in the order Pl-Pz, the tumout time is 30 and 36 units of time respectively
thus
giving an average time of (30 + 36) / 2 33 units of time. Their corresponding
= waiting time is 0 and 30 units of
time with the average of i5 units of time. However, if the process arrives in reverse
order i.e., p2-pi,then the tum
around times are 6 and 36 units of time respectively giving an average of 2l
units of time and the average
waiting tirne is (O + 6) / 2 = 3.
Process CPUTime
P1 4
P2 10
P3 6
P4 J
Operating System 61
According to the shortest job scheduling the processes are served in the order P4-PI -P3-P2.
So, the waiting time is
So, the SJFS scheduling reduces the average waiting time. Shortest job scheduling may be pre-emptive
and non-pre-emptive. But in both the case whenever the SJF scheduler is invoked, it searches the ready queue
to find the job or the process with the shortest execution time. The difference between the two SJF scheduler
lies in the condition that leads to invocation ofthe scheduler and consequently the frequency ofits execution.
Completed
job
Process CPUTime
P1 20
P2 5
P3 t0
If we use a time slice of 5 units of time, then P1 gets first 5 units of time and the CPU is given to the second
process i.e.,Y2.SinceP2needsjust5unitsoftime,ittemdnates,astimeslicerisexpired.TheCPUisgivento
the process P3. Once each process has received one time slicer. The CPU is returned to Pl for additional time
slicer. Thus, the round robin scheduling is :
P1 P2 P3 Pl P3 P1 PI
l0 n % n 35
For implementing a round robin scheduling we require a dedicated timer. The timer is usually set to
intemrpt the operating system whenever a time slicer expires and thus forces the scheduler to be involved.
Processing the intenupt to switch the CPU to another process requires saving all the registers for the old
process and then loading the registers for the new process. This task is known as context swirching.
62 Saraswati lnformatics Practices (Xt)
4.5.5.4 Scheduling and Performance Criteria
We have to use some performance criteria to maximize the system performance. These are :
(i) CPU utilization. It refers to the amount of work completerl in a unit of time. One way to measure throughput
is by means of the number of processes that are completed in a unit of time. The higher the number of
processes, the more works apparently being done by the system.
(fi) Ihrnaround time. It may be defined as interval from the time of submission of a process to the time of its
completion. It is sum of the periods spent waiting to get into memory waiting in the ready queue, CPU
time and VO operations.
(iii) Waiting time. In multiprogramming operating system several jobs reside at a time in memory, CpU
executes only one job at a time. The rest of the job waits for the CPU The waiting time may be expressed
as turnaround time, less than the acfual processing trme.
(iv) Response time. It is most frequently considered in time sharing and real time environment. However its
characteristic differs in the two systems. In time sharing system it may be defined as interval from the time
the last character of the command line of a program or traction is entered to the time the last result appears
on the terminal. In real time system it may be defined as interval from the time an internal or external event
is signaled to the time the first instruction of the respective service routine is executed.
Generally, tr\e scheduler is designed by balancing of all the different requirements and constraints. So, the
system performance is increased and the CPU must be utilized in the efficient manner.
4.6.2 Multiprogramming
Multiprogramming is the efficient way to improve the system performance. Multiprogramming approach allows
CP-U time al"any moment. The more the number of programs competing for system
the resource utilization. The basic idea is shown in Fig. 4.16 shown below :
PrimaryMemory
The operating systeln picks up any one ofthe programs and start executing. During execution the process
may iieEdiome I/O operations to complete. In multiprogramming system the operating system switches over to
next program. When again this program needs to wait for the t/O operation then the operating systern switches
over to next program.
Multiprogramming is traditionally been employed to increase the resource utilization of a computer system
and to support multiple simultaneously interactive uses.
4.6.3 Multiprocessing
ln multiprocessing system two or more independent processors are linked together in a coordinated system. In
such a systern, instructions from diff'erent and independent programs can be processed at the same instant in
time by different processors.
The tenn multiprogramming is sorretimes loosely interchanged with the term multiprccessing, but they
are not the sam involves concurrent execution of instruction s from two ormore
sharins the CPU and controlled bv one isor. In multiprocessing, two or more CPU's are required. The
instructions ale executed simultaneously can execute clifferent instructions ofthe
same program or of different programs at any given time.
Multiprocessing offers data-processing capabilities that are not present when only one CPU is used.
Many complex operations can be performed at the same time. CPU can function on complenrentary units to
provide data and control for one another. Multiprocessing is used for nation's major control applications
such as railroad control, or airways e/c.
4.6.4Time sharing
I V"th,rlen
Tirne sharing is a general term used to describe a processing system with a number of independent, relatively
low-speed, on-line , and simultaneously usable stations. Each station provides direct access to the CPU.
G!r. sharing system, 4jIg!-l-4!11-sutt of time_is-al]_o_g1t-e-d.f-oJ-ea-ah.prq.-c-ej-s.fgf-tllg p19ry9sing
wort<s for one loU fo. that time .sllCe, wtrJch"is defined in milllseqgl{s.
ptogra,nr from monopolizing the processor, a program executing longer than the
is interrupted by the operating system and placed at the end ofthe queue ofwaiting
As in thdTim-e-shariiifsystem the CP[gyilgh,esrapidly from one u-ser to another user, each user is
'ffeil
.p:€-rq*''
an impression that he has his own computer. while it is actually oue computer shared among many users.
This method of processing makes it possible for several users to share the resources of the computer
simu ltanecusly.
This operating system operates in an interactive mode with a quick response time. The user types the
request from the termina[. The computer processes it and a response is displayed on the users terminal.
Memory management in time sharing system provides for the protecticn and separation of user programs.
Input/output feeture of time sharing system must be able to handle multiple users.
4.6.5. RealTime oS ( *ros2
\
Real time proccssing method is one that controls the environtnent by receiving data. Processing them and
te[iusaetron-o-r retqlqi-ng-1e.,eul!: !sft9.-r-e_!1ii-Trifrlip-9{.:ltlrg !!iti"Ug-9f-t!9 9nvir6nme111-11na1 lrye
T'he tenn real time refers to the technique iif updating frles witlithEransaction data irnmediafely alter the
evenr to rvhich it relatei6cc-uffiliislJ*thn diSTiidffi;I'to-5:iic6-prdessing'wfiicli p.roc,i"Sses rel'ated data iir
barcfes at paddafin;d pe"ioaiottirne. Realtime systetnsareb-qlrg]]lglFltlt-L.-pq-ryI tU1Sygy
ploqgqlUr& The response of the system to the inquiry itself is usedlto controlthe activ produglion
i
il p9l9l 94"rrno-t be
gs. ation to monitor
c
tl Wholesale supplier and manufacturer - Availability of stocks.
64 Saraswati tnformatics practices (Xl)
tr Airlines - Flight seat.availability
O Manufacturing - Status of production orders.
R.eal time systems usually operate in multiprogramming and multiprocessing. These increase
both availability and reliabitity of rhe system
Solved Exercises
(a) Dedicated
(D) Shared
(c)
Mrtual
Ql2. What are directories ?
Ans. A directory is a file, which keeps track of all other files.
Ql3. Give some file protection method.
Ans. We can achieve file protection by :
(a) Giving password to the file
(6) The second approach is to make access dependent on the identity ofthe user.
Q14. Define a process.
Ans. A process is a running program with some specific tasks to do.
Ql5. What is a PCB ?
Ans. The operating system groups all lnformation that it needs about a particular process into a data structure
Prog!"omming Lqnguqge
5.1 lntroduction
A language is a medium of communication. In order to communicate with each other, humans need languages
like English, Hindi etc.ln the same manner, for communicating with the computer, we use computer langLrage
called programming language. A programming language consists of all the symbols, characters, and usage
rules that permit people to communicate with computers. There are many programming languages available and
each one has its symbols, character set, and syntax (pre-defined rules).
We know that the computer can neither think nor can make any decision on its own' It needs clear
insffuctions to understand what to do. A program is a set of logically related instructions that al'e arranged in
a sequence that guides the cornputerto solve aproblem. The process ofwriting a program is callcd
programming.
If a system is not correctly programmed; it delivers incorrect information. For example,
lOLETA: IO
20 LET B:20
30 LET SUM:A +B
40 LET PROD: A * B
50 PRINT SUM
60PRINTPROD
TOEND
Frorn the above program, you find the sum and product of two numbers A and B. Here, the program is
written using BASIC language. From the first line, the program will process atl the lines tili the end of the line.
Finally it wiil produce the sum as 30 at line number 50 and product as 200 at line number 60 respectively.
'fhere are three types of languages :
O Machine Language
O Assembly Language
tr High Level Language
Tlre machine language is the only one that computer can understand directly. In the early computers
programmers had to translate instructions directly into machine language form that comptlters understood'
This task is very difficult and very few progranrmers can do this work. So, this language is very difficult to
understand. But the main advantage of this language is that it is fastet in execution since the colnputer
directly
stafts executing it.
(67)
5.3 Assembly Language
To ease the programmer burden, mnemonic ope
early 1950s. The mnemonic refers to amemory ai
process rvas to substitute letter, symbols mnemonics
Each computer now has a mnemonic code, although,
models' Machine language is still used by the computer as it processes
data, but assemble language software
first translates the specified operation code symbol into its machine
language equivalent.
absolute.numeric location,
b nger assign actual address
n location in the program to
b instructions and data.
A program wriffen by a programmer in an assembly language is called
source program. After this source
program has been converted into machine code by an assembLr,
it's referred to as anobj-ect program. The main
advantage of assembly language is that the program written in
it is easy to understand as compared to the
program of machine language. And a big drawback is that
they are machine oriented depending on the model
of processor being used. Also the program written in assembly language
is less fast to execute a"s compared to
machine language.
5.4 High Level Language
truction led, in turn to the development of high level
ass of precession problem.
ams may be used with different makes of computers
be greatly reduced when new equipment is acquired.
(a) Readability. Programs written in these languages are mcre easily readable
than assembly language
and machine language.
(b) Portability. Programs could be run on different machines with little or no change.
(c) Easydebugging. Errorsareeasytofindandremove.
@ Easy software deveropment. Software courd easily be developed
using HLL.
5.5 Translation of HLL to Machine Language
understand only machine language. So, it is necessary to conveft
the entire program
chine language. This can be done with the help of ranguage processors.
Some of the
5.5.1 lnterpreter
Interpreter translates each source program statement into a sequence
ofmachine instructions and then executes
unique
e same,
he time
gram is needed. Another difference is that interpreter
xecute the next line unless the first one has no error.
5.5.2 Compiter
Compiler translates a source prograln that is u
machine language as a whole. The compiler is
series of machine-language instructions or wi
requires a separate compiler. A compiler creates a un
there is no need ofthat source program because ou
Programming Language
5.6.1 FORTRAN
F'ORTRAN is the short form for FORmula TRANslation. As the name suggest it is used extensively in numeric
data types, such as integer, real, float and compiex. It was the only ianguage developed by the IBM in 1957.
Since therr it is rnodified into many types and the latest version FORTRAN 90 is currently available in the
iridustry. The original work on FORTRAN rvas starled in 1954 when an lBM-sponsored committee headed by
John Backus on a scientific language. As the result ofthis effort the FORTRAN was introduced in 1957 for IBM
704 computer. FORTRAN is very,useful for doing scientific and mathematical computations' The main feature
of FORTRAN is that it can handle the complex numbers very easily. But the syntax of FORTRAN is very rigid'
I--OK;RAN language is not suitable for a large amount of data. So, it is not used for business programming
application.
5.6.2 COBOL
COBOL statrds for COrnmon Business Orientei! Language and is one of the'popular languages used for
business applications. The Ianguage has provisions, which make computerization of business data processing
procedures relatively easy. COBOI- is suitable for processing large volume of data and several reports can be
generated using COBOL based on stored data. COBOL programs are characterized by their easy readability due
to their verbose syntax, and good data organization and file handling.
COBOL is an English like ianguage rvith instruction coded using self-documenting English words rather
than short abbreviations. AIso, the rules of programming in COBOL conform to many of the rules for writing.
Due to English like nature of the language, COBOL programs are easy to read and write. Thus, the people in
business who rely on colxputer output, but have no computer expertise can understand the programs written
in COBOL. That's why COBOL, is called a self-documenting language which is self-explanatory.
COBOL was initially deveioped in 1959 by a group called the CODAsYl(Conference On DAta SYstems
I-anguages) Cornmittee with the objectives of developing a standard business-oriented language for which all
nranufacturers would provide compilers
rnaj or "
"Ihe American National Standards Institute (ANSI) then formed an ANSI COBOL comrnittee to develop
more satisfactory standards for the language. This led to the availability of ANSI COBOL in 1968. This standard
was however modified and finally approved in 1985 and so it is also referedto as COBOL 85.
s.6.3 BASIC
Basic stands fbr Beginners' .All-Purpose Symbolic lnstruction Code. It is the most popular conversational
language. The main characteristics of the basic is to handle both mathematical and business problems. This
tranguage was deveioped specially for the time sharing environment but can also be used as a standard
prograinmirrg language in batch-processing environnrent. This language is easy to understand' But the main
probl., in BASIC is that most versions of this language Coes not support indexed files.
5.6.4 Pascal
pasca,l is a high l,evel Langua-9e, which was ,Jeveloped by the Prof. Nickalus Wirth at the Eidgenossisehe
Houcheshule tgfHl in Zgrich. Switzer[and. The first report on the language appeared in the
-l-cchnisehc
literature in i 97 I and revised repolls clescribing the language with its improvetnents appeared during 1972 and
i 973 . The first Pascal refereuce manual for Pascal programmers was produced in 191 4.
pascal is a general-purpose language, which can be u:;ed for wide range of nutneric and non-numeric
r1lplicaticns 'i:iir.- nrirnail ob.iectives behind the developme,tt of Pascal were:
The language should be efflrcient to implement and easy to execute on
? today,s computers.
q The language should be used for teaching about the important concept
of computer prograrn,1ing.
O The language should be used for the development of wett structured
and well organized programs.
The abore features make pascal as a very good introductory programming
language.
s.6.5 C
C is a general-purpose structured programnring [anguage. C is character
izedbythe ability to r,vrite very concise
source programs. The compiler of C is corrmonly ava-ilable for the
computers of all sizes. The c<lmpilers are
usually compacl and they generate object programs that are srnall and highly
efficient as compared to the
programs written in any other language. The programs written in the
C language are highly portable, that is the
program written for one computer with very ttw clranges can run on
anotherionrputei. The reason forthis is
that C relegates most computer-dependent features to its library functions. Thus,
every versio;r of C is
accomplished by its own set of library functions.
Dennis Ritchie originalll' developed C in 1970s at Bell ]'elephone Laboratories.
It was the modified version
of two earlier languages, called BCPL and B, which were also developed
at Bell Laboratories.
5.6.6 C++
C++ 15 6n object-oriented prograinming language. As software systems
develop into more po,,verful instruments,
they also beconle more complex. Every new release ofa word processor,
database, or spreadsheet program is
longer than the previous one, and contains more features. This
increasing size and complexity makes it difficult
to manage the software development process. As programmers struggle
to deal with this complexity. new ideas
emerge' one collecticn ofthese ideas is based on aphilosophy calLd
object-oriented prograrlming.
While obf ect-oriented programs can be written ir
languages such as c or BASIC, these lar-rguages lack
certain feafures. For example, C provides no mechanismto hide variables
fi,orn nnauthorized access. C also does
not en lass ofanother. The lsnguage
by Dr. I Labs in the early I
1' the C++ Ianguage. .ee
states.
called r* and future C++. existed.irr
released Af&T versions and that all serious cornpilers support,
contemporary C++ consists of traditional C r I
rvith sorne nevr features which are approved by the comrniitee but
irnplemented by only few coppiiers. Future
C++ 15 the larlguage. which is under discussion in the committee with new
t'eatures that are approved - but not
yet implemented."
The uage, as expressed by the designer himself at a deverloper cont'erence. is
t
to rnake ng a natural part of the languag-e. The three ciefining traits that rnake r.r
C
an object ulation, inheritance, ana potyriorphism. \\rhen we look carelulll,at etrc5
of these traits, we see that chapters support or cornplement thenr.
5.6.7 JAVA
Java is developed by James Gosling the chief programmer of Sun
Microsysterns. Java is an object oriented
progratnming language. vvhich rvas developed after C+t-. Java was
designed to be srnall. simple and portable
across platforms. James Gosling star-ted a project on controlling
.onrrr., elcctronic clevices with a Ianguagc
cj'-l'' Atler some titne he flound that the C] t--i- rvas not suitable for ihe projcct. They faced
rnany problerns lvilh ttrc.
complicated aspects of c++. with progrant bugs arld memory lcaks.
So, Gosling decidecl to develop ncrv
language, which could overcome thesc problerrs.
As Gosling liked the object orientecl features sf ft+r-so he decitled
to take C++ as thc base for.the nerv
language. He developed a new language oak, rvhicrr was rater
cailed Java.
Java is nrost poplrlar because it is used fol internet prograrnnrirrg. previously
only HTMt, was use6 for
creating web pages. But it is difficult to depend on onl,v o* tunguu!.
for deveiopin! tne application, as is
clivcrsitv exists on tlre intcrnet itr ternts of harcl,,r'alc and soltu,arc.
se.virs on the internet have to store nrultiplc
Programming Language 71
copies of the same program cornplied fbr different hardware and software environment.
Java is the answer to these problems that exists on the internet. In Java, you can write a single program
(called an applet) that is platform-independent. Platfonn independent means that the program can be used at
any platform with any operating system. 'fhe applet can be executed by any internet. Java is an object oriented
language as that of C++ but it has some difference as compared to C++.
In Java, there are :
tr No pointers
O No multiple inheritance
O No goto
n No operator overloading
In C++ we can allocate and deallocate the memory by nerv and delete. The Java language has an ernbedded
auto garbage collection mechanisrn. The garbage colle ctor simplifies Java programming by automatically freeing
,.,*ryu."u*henitisnotrequired.SoJavaissitnpleascomparedtotheC++.Javacodeisdividedintoclasses.
Java isiike any client/server model. Java is reliable. A reliable is one that allows you to write programs that do
not crash when least expected and will also be bug-free. Java is comparable in speed to other languages like
g++. Java has sophisticated multitasking features are integrated into the language which itself, which make it
very simpie to use and, at the same tirne very robust.
5.6.8 Visual Basic
VISUAL BASIC is a high level programrning language evolved from the earlier DOS version called BASIC.
BASIC means Beginners' All-purpose Symbolic [nstruction Code. It is a fairly easy programming language to
learn. The codes look a bit like English Language. Different software companies produced different version of
BASIC, such as Microsoft QBASIC, QtIICKBASIC, GWBASIC ,IBM BASICA and so on. VISUAL BASIC is an
event driven Programming. T'his is the main divergence from the old BASIC. In BASIC, the program is executed
sequentially. In VISUAL BASIC, due to its \\/indows Interface, the users may click on a certain object randomly,
so each object has to be programmed independently to be abl e to response to those actions (events). Thsrefore,
aVISUAL BASIC Program is made up of many sub-programs, each has its orvn program codes, and each can
be executed independently and at the same tirne each can be linked together in one way or another.
s.6.9 C# (C Sharp)
C# (pronounced "C sharp") is a nerv language designed by Microsoft to combine the power of C/C++ and the
prodirctivity of Visual Basic. Initial language specifications also reveal obvious similarities to Java, including
syntax, strong web integration and automatic memory management. So, ifyou have programmed in either C++
or Jal,a, adding C# to your knowledge of langtnges should be fairly straightforward.
C# is a modern, JAVA like, object-oriented language that enables programmers to quickly build a wide
range of applications for the new Microsoft .NET platform.
5.6.10 vb.NET
.NET framework has been pluggecl by Microsoft as a new progranrming model for the Internet age' Personally
I prefer to think of it as a new programrning model for almctst et,erything, that is V/indows related.
Seriously, if you are working with Windows programming, then I believe .NET is going to be well worth
learning for future projects, sinrply becattse it will rrake progratnming rnuch easier.
The most significant aspect of .NEl' architecture is that code in VB, and C# is compiled not to nativc
executable code, but to an Internrediate Lung'uage (lL),with the final step of converling to native executable
lornrally happenirrg at runtime. Such code is terrned ncrnaged code C++ code can optionally be marked as
managedcode.irrrvhichcaseitgctscompiledlolLtoo.ThismakesyourC+l codeinteroperablervithVBand
C# and allows 1,ou to take advantage of all .NET features, but does restrici you to not using some features o1'
Most of the 4GL languages are used to get information from files and
databases. The SeL (Structured
Query Language) is the common example of 4GL language. Ifwe have to find the name
of student,,Rohan,, then
v,,e rvill write the t'ollowing statement in SeL:
Solved Exercises
Bevlew Questions
l. What is prograrnming ?
(a) FOMRAN
(6) coBol
(c) BASIC
(@ Prolog.
8. What makes JAVA different form C++ ?
9. What is a programming language ?
10. What is HLL ? Give some examples.
ll. Write the advantages of HLL.
12. Distinguish between COBOL and BASIC.
13. Who developed PASCAL ?
14. Name some scientific languages and business application
languages.
15. Who developed JAVA ?
16. What do you mean by 4GL? Give some examples
of4GL languages.
17. Write short notes on the following :
(a) CoBoL
(b) PASCAL
(c) c
(d) Ct+
(e) JAVA
Chapter - 6
6.1 lntroduction
Operating system is a set of programs, which manages the resources like hardware and software of the
colnputer, pl'ocesses comtnands, and controls program execution. As the foundation of all computer operations,
it is the most complex program executed on the computer.
-fhc
operating system is the software loaded into memory when a computer starls. This concept is called
trooting. While booting, the operating system organises all hardware and operating program instructions to co-
ordinate between them. The operating system is the software, which makes the computers ready for us to use.
It tells the processor to do its jobs, i.e., obeying the commands of the user.
Once the operating program instructions are loaded into the memory other applications like word processors,
spreadsheets. databases, paint programs and other progratns can be executed easily ; since these softwares are
application programs which run under an operating system.
'l'he rnost popular operating system is MS-DOS (MicroSoft Disk Operating System), MS-Windows 95/98/
2000, Windows NT, OS2, Lynix and UNIX (multi-user operating system).
.,vith computer by typing
MS-DOS and UNIX are Character User Interface (CUI) that makes communication
conrnraud lines.
(75)
76 Saraswati lnformatics Practices (Xl)
,#
**#,
llp
6.3.2 Taskbar
It is a strip (bar). It is along rhe
bottom of the screen in windows 95/
98. The names of all open windows
are displayed on the taskbar. you
can quickly switch between
windows using taskbar.
Start Menu
Fig. 6.2 Windows deskop.
6.3.3 Start Menu
On the left of the taskbar, a box with name Start is displayed. This button is used
to stafi difi-erent programs or
applications. When you press the button, a menu is displayed (as shown in Fig.
6"3) to execute the program.
6.3.4 Menu
It is a list of options displayed on a computer from which you can choose. Menus
may be in words, pictures or icons. There are pull down, popup and pop down
menus. Menus help us to move around a software program. For instance, from the
start menu of windows 95/98, there are number of options like shut Down..., Log
Off..., Run ...., Programs , etc., catbe chosen.
In the above figure we see a series of menu commands such as File, Edit, View, Go, Favorites and Help'
This
line is called as the Menu Bar.
Each of these menu items has several options within it. From the File menu click on the File on the menu bar,
we will see a pull down menu with NeW Open, Save, Save As, Print and Exit will appear on the screen'
Once the drawing is made, you might have to make some changes in it. Such as copy, cut, moving
and
part oi image editing. If you do not want to delete or cut the portion or whatever last
pasting, etc. Allthese are a
click on the Undo option in the Edit menu. You will get back the former result or you will
action you have taken,
get original picture.
In the View menu, there are six options available :
1. Toolbox - This option will show or hide the toolbox. Tick mark against the toolbox indicates that the
toolbox is currentlY oPen.
2. Color box - This iptilon will enable you to show or hide colour box at the bottom of your paint area.
A tick mark against colour box indicates that the color box is currently open.
3. Status bar - This option will enable you to show or hide Status bar, which is displayed at the bottom
of the paint window.
4^ Zoom -This option has number of choices like : Small Size, Large Size, Custom, e/c.
5. View Bitmap The drawing will be displayed in full screen without the menus and other tools' Click
-
on the drawing area or pressing Esc key will retum to normal view'
A tick mark against the text
6. Text Toolbar - This oftion enables you to show or hide the text toolbar.
tvolbar should be which means this toolbar is activated'
menu'
You can change the size of your cartoon by using the Stretch/Skew option from Image
6.3.7lcons
The icons are the small pictures on your desktop as
shown
in Fig. 6.6. These icons are used to run specific programs
and are known as the shortcuts to those programs.
Normally,
you will find number of icons on a desktop.
Openning
Microsoft Word
using right-click
Open
From the above figure contents menu, move the mouse pointer to Open option and click left mouse button
to open the program, file, or folder. You will see that Microsoft Word window will appear as shown in Fig. 6.9.
ilbla:$r-rridSin,HGlp:, , :. :: X
,, , , ]..
!
,:rFgqltrl d 1? EC
il (rrrd -^ ?:68
l:1 rreel ?e/i ils
D Doubte-click the icon of the drive you want to work. For example, click on C: as shown in
Fig."6.13.
Namu
tBmp File Fulder 'tzl24l0D 7..^ ;,
Before browsing floppy disk drive A:, make sure that your drive contains a floppy
disk. Here browsing is
to move through the floppy disk, any other disk, on the windows or on the Internet.
tr Type a name for the new folder as MYFOLDER, and then press ENTER.
t"l
r
Now your folder "MYFOLDER" is created in C: drive. ;]
E-yr4-oEBtr
Note' Ifyou wantto create a newfolder within afolder, cHck thefolderand then followsteps
as explained above.
ir,i: lr I
tr Use the [,[*'$1 (Maximize) button to enlarge the window so that it covers the entire desktop (except for
the taskbar).
n Use the
{ (Restore) button to return the window to its pre-maximized size.
D OpenthefolderMYFOLDER.
D In the MYFOLDER window, click on File, New and click on Text Document option as shown in the
Fig.6.17.
Uodo
uEtillltElt
:!
----J
F$farts
faftl
.,1
I
IErbo6
U[. C{Jf
tefql.- "
Ncdtrec f ltP
_l __l
I
"r l
Pmf ---JFiles
F.sgrum Prilo*t$
t-1 , \Y'
, -"-1
,{ i ..) ___i
rcata scot gBrios Tall/
I
J -.--J
temF Turboa
Fully
expanded
drive
Folder 7/4101 A:58 PM
F aldet Right Panel
Frle l-oldar !01 2 42 Ptl
'i
Left Panel_ l: r!
'0.1
l.licrosoft Word
llicrosoft Word
27KB 3/l {ml l0:00 AM
E2KB 7i2Bl01 1t 40 AM
, JAmarRoh E--rca 09 l{icrosol1 Word 73Kts 5129/01 r 33 PM
-t clsl I083 fics-i4 Microsorl Word 29KB I 2/29/00 S:56 PM Date created
Folders/ EdrtPad csl Mrcrosott Vlord 4OKB 3,/r 9/01
6.13.1 Program
Once you know way around the desktop. you're ready to begin exprementing with programs. The start menu
conatin one option known as Program. This is the first Start menu item. You will find a symbol ) right of
Program. Whenever this symbol appears it means that the menu item is selected, a second menu will appear to
the right. You can run any appliaction which is present in the staft menu by simply clicking over it. For example,
to run Run WordPad do the following :
l. Click the left mouse button on the Start button on the Taskbar.
2. Move your mouse up to point toPrograms - no need to click. The available programs and groups will
appear to the right, as shown inFig.6.24.
3. Move your mouse to the nght to point to Accessories. Again available programs and groups will
appear to the right.
4. Click the left mouse button on WordPad.
6.13.3.1 ControlPanel
When you click on the Control Panel option the following screen
will appear:
,iir ,7'.;, li; . . li
The icons which are present on the control panel are LBQftrS,:tsBl "",
various programs provided with Windorvs. For example, Add . , ,,I :!:.'1.'
$hjt Bryrn;., .,,,
New Hardware option helps you to install new hardware device.
There are other option also we will discuss in detail in this
chapter. Fig.6.26 Settings option in start menu.
6.13.3.2 Printer
The Next option the setting
is the Printer. This option
helps you to install new
printer in your computer.
When you click on the
J Print<r
Printer option the following ;i hp de*kiei !4Sc eaieE 0 Llser lnle
screen will appear as Printers desl.jef 918c ;erree [2] 0
tp LaserJet I 000 a
shown in Fig. 6.27.
LBssJet 1000 DOS 0
Thts folder contains LaserJet 6P 0
information €bout your La*erJet 6P/6MP. EnhancEd 0
currEnt printers 6nd a
wizard to help you HP LaserJet 6PlEl'4P - Stendard 0
irstall rerq ones
To get infornrsticn
about d printer thst's
already installed,
right-click the printer's
rco n.
I
Usingbasic search, ycu indicate the file name or a portion of the file name (if you don't know it all) and
a
search either your entire computer, or any drives or directories that you choose.
tr You saved a Word document to your hard drive [C:] but you can't remember the name or where it was
saved (but would recognize it). The syntax for entering into the 'Named:' box would be :
*.doc (this shows all files with a .doc extension)
*.ppt (this shows all files with a .ppt extension)
tr You want to hnd the hle called 'budg-req. but you only remember part of the name
-
'budg'. The
syntax would be budg* (this shorvs al1 files beginning with budg).
tr In the 'Look in:' box, click the Browse button and click on [C:] so that the search will starl from the
main level or root of the C: drive.
O Then click on 'Find Now' to stafi the search as shown in Fig. 6.30.
dl$
?w
[.1tm1$6,$*d$i!
t,..r,'
-'{x.ea, -'. - . tli*1**l
ii."
-,. J
tB.?a& lft'
leh 6r:
---- ';a
. ?'}
{i 1mlird*5,.iAorUm '
Modittsd
E866CC -l ctProgra gl KB Mierosoft 3t6t01 B'03 P
s fiSt lleo!
G.13.5 Help
When you ciroose this option windows will display you the HTI,IL Help engine whieh displays HTML pages
containing help information. You start Windows help by clicking start , Help. The following Fig 6"31 appe
ar on
your screen :
Prom the Run dialog box, Click Browse button to see the Browse diaiog box for exploring CD or other drive
contents as shown in Fig. 6.33.
?d r$t 'l(D
t;il q8i.E,il
II Deskt[p
I# 3x Fl
$ kty 0ocurnanls
y (6mpuler 'it
7 ':ttr, ,_. {
Frhsar*e m I
'\1 r
Fih"'r$g,,pe: Carce! l:
Fig. 6.34 Running a game using start.
D Quick Launch. By default, the Quick Launch toolbar appears just to the right of the starl button on
-faskbar.
the When you install Windows, Setup automatically places four useful icons in the
euick
Launch toolbar : Internet Explorer, Mail, Show Desktop ancl View Channels. The Launch
euick
toolbar provides one-click to access to your most commonly used application.
To add olvn shortcuts to the Quick Launch toolbar, drag the file or shoftcut to the
euick Launch toolbar
and a shortcut is created for your application or file. The Listing 6.1 describes the four buttons added
to euick
I-aunch during the Windows instatl.
listing 6.1 Built-in Desktop Toolbars.
Internet Exp I his is the shorlcut to [nternet Explorer.
Mail This is,a shortcut to Microsoft's mallager outlook Express. outlook Express i
incluced with Interent Explorer 4.x.
Show Desktop This is probably the most useful of the four buttons windorvs piayce on the
eujck
Launch toolbar. If your desktop becomes cluttered with open application windows
or if your current application window is maximized and you need to get to"your
desktop, click the show desktop icon and all your windows are automatically
mrnrmized. click the icon again and all your windows are restored to the previous
state and position.
Vier.r, Channels. when vou click this button, you get a full screen browser to view your channels.
Ifyou have not set up your Internet access, the Internet connection wizard wil
guide you through the setup.
tjl
ti
t^;, llentel
r,i
,r. {'.!L ':i/j,
t '.:i! '/ ririjir'lt('." '
:t: .
' .,.{
in!
$l'
li'
:ir+
li. ;
1. From the Display Properties dialog box, select the Setting tab,
2. Click the down arrow to the right of the Color drop-down list, and select the number of colors you
want for your application.
Conlrol Parel
-L:.:il
Accessibilty A,id Netr AddlRemDve Adobe 6amma DatelTime rplay
Control Panel Dptions Herdwrre Proqdmg
D
Select.n item
desrription.
tD virN iiJ
$ *g"Sg
Msdems l'loue l'.lullinredia N<tvsrk nDBf, 0Eta
l,ltt,'asDft H,!n',r Sourcqo f32bt)
lsshlr-sdLsrrp.lrlr.r
:p
Symontec
LiveLlpdate
Syslem
dS
'J
Teleflrory
6Ucers
"f::'"i)'ry-
4. Notice Add New Hardware Wizard offers two options for installing the new hardware :
3. To install a new software click on the install button. The following dialog box will appear as shown in
Fis.6.44.
To qet inf€rm3tiDn
+bcut a printer that's
6lreddy installed,
riqht-click thB printer's
tc0n,
6. When you click on Next the following dialog box appear as shown in Fig. 6.48.
q& lu Fq nrqr:ii{$ F
t:
1. Click on the Control Panel >> Date/Time tab. The date/time properties dialog box is displayed as
shown Fig. 6.52.
rr€ I
'.\8
n,i
1 2
4 5 c :o e lil
11 12 13 't4 15 tn 1l
'18 1€r 20 21 & lar !d
window'
Fr.m rhe Fig. 6.5-:, click tabs and set your number, currency,
,,*" .#l;l;t:T:::l:*ttings
6.18 Shutting Down your Computer
Before switching off the computer, you must close
all the opened progr.ams or files so that the work
done does not get corrupted. In Windows, the
shutdown feature helps you to close all active
operations safely and allow you to s$,itch off the
computer.
To shutdown the computer :
0ptions Effcct
Stand by A stale in which your ccmputer consumes less electric power when it is idie, but
remains available for irnmediate use. Typically; you would put your colnputer or
standby to save power instead of leaving it on for extended periods. While or
standb1,, information in computer lTiemory is not saved on your hard disk. If the
computer loses electric power, the information in ntemoty rvill be lost.
Shr. t down Saves any Windows settings that you chan-*ed and writes any infornration that it
currently stored ir.r memory to your hard disk. This prepares your computer to be
turned off.
Restart Saves an1, Windows setting that you changed, writes any information that is currentll
stored in memory to your hard disk and then restans your computer.
Restaft in Saves any Windows settings that you changed, writes any information
MS-DOS mode that is currently stored in memory to your hard disk and then restafts your computel
in MS-DOS rnode.
Solved Exercises
Fleview Questions
Windows Accessories
7.1 lntroduction
immediately without having
windowr 95/98 comes with a number of applications that can make you productive
pointing to Programs' pointing to
to install expensive software on your.yri*. Clicking on the Start button,
can start most of these applications' You should find
Accessories, and then clicking on the lppHcation name
on your systcm and we'll take a look at each of these :
the following applications if ttey have been installed
7.2 Notepad
from documents created by
There will be tirnes when you will want to edit textual hles. Textual files are different
WordPad, Word or WordPerfect or some other word processing program in
that they contain no imbedded
special characters that make these files
codes. Editing these flles with a word processing program can inffoduce
unusable. Instead, use Notepad which allows you to edit the file as pure text.
purpose tlles in Windows
Textual files will normaily have a TXT file extension, but there are severdl special
AUTOEXEC'BAT'
that must be pure text. Sorne of th. ,no." important of these include your CONFIG'SYS'
If so, use Notepad to
WIN.INI and SysTEM.INI. you may get to the point of wanting to play with these files.
f,rle' If you decide to create a web
edit these and not WordPad as your system.*ot ur" the resulting WordPad
yourself from the nasty characters
page, but don't have an HTMleditoi you will like to use Notepad to escape
associated with WordPad, etc.
To start NotePad :
(107)
108
7.2.1File Menu
This is the File menu, as shown in Fig.7 .2. Notice a co
notice that there are underlined letters on each selecti
each item with your mouse, you cau do it with the key
Nerv - This will start a new document. If you are currently working on a clocument that you l
haven't saved, the system will prompt you to save the old document before starting a
1
new one.
Save - If you are making modifications to an existing file, Save will put the changes back into the file after
confirming that you really want to make the ctranges. If the file you are working on is a new frle. Save works
the same as Save As....
Save As... - Save As... hrings up a dialog box similar to the Open riialog box as above.
By default, Notepad will
save a new fiie in the My Document foider. It's easy enough to change folders and save
a file anyryhslg o,
the system you want.
Page Setup... - The Page Setup...
diaiog box allows;vou to custonize
some of the things you see when
you print your document. For
example, you can change the size of
your paper; customize the header
and footet on each page as well as
the margin at the top, bottom and
either edge of the paper. The page
Setup... dialog box, as shown in Fig.
7.4.
He&dFr;
l+c,liv
Print - Thrs is a standard print operation sending the information to the default printer. The only way to change
the printer is to change your defauit printer.
Exit - This shuts dorvn Notepad. If the file you've been working on has not been saved, you will be prompted
to save the file before Notepad exits.
Undo - Notepad does have a rather neat feature called the Undo. trf you make a mistake and
suddenly say to reffieve, you can select the Undo and reverse whatever it was you just did.
Cut - Again, this item is only available if you have something selected in your document. Otherwise you have
nothing to Cut.
Copy - CopS is very similar to Cut. The only difference is that with Copy, your selected text is not removed from
the document. Instead, a copy of your selected text is placed on the Clipboard for you to use later.
Paste - Once you have some text on the Clipboard (using either Cut or Copy above), you can move to wherever
you would like to put this text and Paste it back into your document.
Delete - When you Delete text from your document, it is gone. If you do this by accident, you can use the Undo
function to bring it back, but otherwise it is gone. Delete does not place the selected text on the Clipboard.
Setect All - If there is something you want to do with all the text in your document at the same time, all you have
to do is select the Select AII function and your entire document will be selected. Now you can either Cut
or Copy all the text to your Clipboard.
Tirne/Date - The Time/Date function is a neat feature of Notepad. Some people like to keep a journal and in a
journal, you might want to have the date and time as part of the document. Obviously, you can type in the
date and time, but with the Time/Date tunction, Notepad will automatically insert the date and time hke this:
7:47 AM l5ll2l200l.
Word Wrap - This will take words that don't fit in the Notepad window and wrap them down to the next line.
Set Font... - This allows you to change the font used to display the file you have open. It doesn't change the
font of the file itself. It simply allows you to view/edit files using whatever font you wish.
rod*&a*
I- tH$*fi'gess
*itli ..aE j.rf "rr,
result, the Help Topics shows all detailed operation of Notepad as shown in Fig. 7.9.
,
firdai
4Stt:'.j1 I .
7.3 WordPad
For those who want something more powerful than Notepad, Microsoft makes available a word processing
program called WordPad. WordPad provides a numher of features found in more sophisticated word processors
including fonts, sizes, colors, e/c. Some people find the power of WordPad to be sufficient for their purposes.
To start WordPad :
lk E& Ytetq
Notice that some of the items in the File menu have a key combination
on the right (Ctrl+N, etc.). These are hot keys that can be used from within
the document without having to go to the File menu.
New - This will start a new document. If you are currently working on a
document that you haven't saved, the system will prompt you to save
the old document before starting a new one.
Open... - This allows you to bring an existing document into \{ordPad to
view and/or edit it.
F'ig.7.11 File Menu.
You'll see the following dialog box, in Fig. 7.3, when you make this selection'
as shown
Save - If you are making modifications to an existing file, Save will put the changes back
into the file after
conhrming that youieally want to make the changes. If the file you are working on is a new file, Save works
the same as Save As....
Save As... - Save As brings up a dialog box similar to the Open dialog box above. By default,
WordPad will save
a new file in the My Document folder. It's easy enough to change folders and save a file anywhere on the
place where you save your files rather
system you want though. I would encourage you to create a special
than putting them;r the Windows folder.
print... printer. Contrary to the way
- This is a standard print operation sending the information to the default dialog box in Fig' 7'12'
Notepad works though, WordParf allows you to change printers via the following
print preview - Wordpad offers a neat feature of allowing you to view your document, as it will look when you
print it without actually having to print it. The Print Preview will look something like the Fig.
7' 13'
you when you
fage Setup... - The page Setup... alutog box allows you to customize some of the things see
Cut -This item is only available if you have something selected in your document.
Otherwise you have nothing to Cut. Cut removes the selected text from your
document and puts it on the Clipboard. The information is not totally deleted,
but is being held in case you want to put it somewhere else.
ltli.
Copy - Copy is very similar to Cut. The only difference is that with Copy, your
selected text is not removed from the document. Instead, a copy of your selected
text is placed on the Clipboard for vou to use later.
Paste - Once you have something on the Clipboard (using either Cut or Copy above),
you can move to wherever you would like to put it and Paste it back into your
document.
Paste Special... - The Paste Special... function allows you to bring in information
from another file.
Clear - When you Clear text from your document, it is gone. If you do this by accident, you can use the Undo
function to bring it back, but otherwise it is gone.
Select All - If there is something you want to do with everything in your document at the same time, ali you
have to do is select the Select All function and your entire document will be selected. Norv you can either
Cut or Copy everything to your Clipboard.
Find... - This function opens a dialog box (refer Fig. 7 .l) that allows you to enter the text you want to search for
along with a couple of pieces of information to help WordPad perform the search.
Find Next - The Find Next function simply locates the next occurrence of whatever it is you did the Find... on
in the first place.
Replace... - The Replace... function can locate and replace text within your document. Simply tell Replace...
what you want to locate and what you want to replace it with and WordPad will do the rest (refer Fig. 7.15).
standard toolbar.
Ruler - This is a toggle that allows you to display the ruler showing you the typing area for
your document.
Fig.7.16View
Status Bar - This is a toggle that allows you to display the status bar at the bottom of your WordPad window.
Options... - This function brings up a dialog box that allows you to set up the view you want for each of the
different types of files that can be edited with WordPad. You don't have to have a file open in order to
customize WordPad for a particular type of file. The dialog box you get should look something like
Fig.7.17.
Help Topics - WordPad contains a few more bells and whistles than Notepad, but is still simple to use. The Hetp
Topics (as like as Fig. 7.9 of Notepad help) is a little longer than in Notepad.
About WordPad - The function of the About for any program is simply to let you know what version of the
progam you are running.
7.4 Paint
Paint is a very powerful drawing program that allows you to explore your artistic creativity. With Paint' you can
create bitmap (BI\{P) hles that can be used as wallpaper as we discussed earlier. A typical Paint screen is as
shown in Fig. 7.23.
Title bar
Menu bar ts6n
-r'
,?
f*
PAiNTAREA
il
Save As"' - Save As"' brings up a dialog box similar to the open dialog
box above. By default, paint will save
a new hle in the My Document folder.
Print Preview - Paint offers a neat feature of allowing you to view your bitmap.
as it will look when you print
it without actually having to print it. You won't actually be able
io see the bitmap, but will be able to see the
layout. The Print Preview will look something lik efrg.l .ZS.
Page Setup"' - The Page Setup... dialog box allows you to
customize some of the things you see when you
print your bitmap as shown in Fig. 7.4.
to the default printer. Contrary to the way
box (as like as in Fig.7 .12).
a the dialog
I
Set As lYallpaper (Tiled) - This function saves you the hassle of saving the bitmap and then setting it as the
wallpaper on your desktop. In this case, the bitmap is tiled rneaning that it is repeated to cover the entire
desktop.
The Edit rllenu, as shown in Fig. 7.26 contains those functions that allow you to ""..,.,".",^...,-
manipulate the information you have on the screen. 1.:
;- :/ -1
Undo - Paint has a rather neat feature called the Undcr. The Undo item will only work on F$o{* Dd+V
!" ,r,.ii,.."i\ l|,
the three most recent change-s you've made to your bitmap.
b*t&tr cE u.ll+F.
Repeat - If you made a change and suddenly decided you didn't want that change
and pressed the Undo - button only to realize that 1.ou really did want the change, ,-'',ti'fJ"., :.'
FgsleEo*r-,, r.l
you can use the Repeat function.
Fig. 7.26 Edit Menu.
Cut -You can select some piece of your bitmap by clicking on either of the first two items on the Toolbar and
drawing a box around whatever you want to select. Your selection will have a dotted box around it. Now
you will be able to Cut this selection.
Copy - Copy is very similar to Cut. The only difference is that with Copy, your selected area is not removed iiom
the bitmap. Instead, a copy of your selected area is placed on the Clipboard for you to use later.
Paste - Once you hirve something on the Clipboard (using either Cut or Copy above), you can nlove to
wherever you would like to put it and Paste it back into your bitmap.
Clear Selection - This iunction removes whatever you have selected from your bitmap.
Select All - If there is something you want to do with your entire bitmap at the same time, all you have to do is
select the Select All function and your entire bitmap will be selected.
Now you can either Cut or Copy
everything to yr;ur Clipboard.
Copy To"' - The Copy To... function takes whatever part of your bitmap you
have selected and makes a copy of
it and allows you to store that copy into a file.
Paste From'.. - The Paste From... function allows you to brirrg
another bitmap image file into the bitmap on
which you are currently working.
7.4.3 VieW Menu qigci i,,lrry !B{
Flip/Rotate... - This function allows you to flip your bitmap or a portion of your
bitmap either horizontarly or vertically or rotate your image 90i, 1g0
" or 27ff.
The dialogbox you'I see will look something like rig.i.zs of image
menu,s
(see Fig. 7.28) FIip and Rotate option.
csfu$: . l
r:rrrarffir'r
8*eic
rr;
$ffiw ffiffi
,w#flrilffffi'
'
Effi*#ffir*mr
l' , "q :'s,:.1
-'
rrrrr'
*.l*--
7.4.7 ToolBar
This icon allows you to select an irregularly shaped object from your picture in order to cut/copy it
r,q,'$l
somewhere else either within your picture or to another application.
This icon allows you to select a rectangular section of your picture in order to cut/copy it somewhere
l;frxl else either within your picture or to another application'
,e,i As this icon implies, you can use it to dump color into your picture.
This icon looks like an eyedropper that can be used to pick up a color from one place in your picture
#,1 and put it somewhere else.
12O Saraswati lnformatics practices (Xl)
This icon allows you to magnify ihe picture you are working on. You can increase the size of the
picture two times, six times or eight times.
This icon acts as a paintbrush allowing you to paint the color select on the Color Bar onto your
picture in a number of different pattems.
This icon looks like a pai,t spray can and works pretty much the same way.
s*l
This icon allows you ro add text to your picture.
&"'
tt This icon allows you to draw a straight line in paint.
This icon is tricky. To choose the width the curve will be, click a line width at the bottom of the
a. ToolBar. To choose the color the curve will be, click a color. First draw a straight line as above. Click
where you want one arc of the curve to be, and then drag the mouse pointer to adjust the curve.
I This icon worksjust like the icon above except that the rectangles produced have rounded corners.
l6Fffi Xff ffi ffi I& p#ff 6*ffi ffi ;"H 3il ;;:J:,#.i,:: ;T::ffi1,ffiil::11"1t3
color can be selected simply by using the left mouse button to
select a color. The background color is selected using the right mouse button.
As you can see, the character Map can be a very powerful tool, as shown in Fig. 7.31.
The Wingdings font is one of the favourite fonts. It provides characrers not available on the
standarrj
keyboard. By using tI:se characters, you can enhance your documents and make them much
more interesting.
Ifyou single-click on any ofthe characters, it'lI blow up so you can get a good look at it. Ifyou double-click on
a character,it will be copied to Characters to copy in preparation for puiting them into your document. Once
you have characters in the Characters to copy area, you can click on the Copy
button to place these characters
on the Clipboard so you can Paste them into another aoplication.
Windows Accessories 121
7.6 Glipboard
The Clipboard is an essential sheif within Windows that can hold one object at a time. An orrject can be a letter,
word. paragraph and/or graphic. An object can be piaced on the Clipboard from any \\'indows application.
That same object can then be placed into any Windows application repeatedly undl the contents of the
Clipboard are rcplaced.
There is a program called the Clipboard Viewer that allorvs you to work with the contents of the Clipboard,
as shown inFig. T .32.
--q
u*3
Ei* E# &isBlay &eb
Cut Removes the selected object or text and places it on the Clipboard so you can paste it elsewhere.
-
Copy - Makes a copy of the selected object or text and places it on the Clipboard so you can paste it elsewhet'e.
Paste - Inserts the object or text that is on the Clipboard. This con.rmand is available only if you have cut or
copied an object or text.
7.7 Clock
Most computers come with a built-in clock. This clock is used by the system to prioritize files an<i operations.
Every file that is stored on the computer carries not only the name of the file, but the size, date and time the file
was created or last modified. Windows 95/98 provides a means for displaying the clock as rvell as changing the
clock. To adjust the clock, double-click on the ciock on your Taskbar.
122
By double-ciicking on the time on the Thskbar, vou can change the date and time for your computer
through an easy-to-use dialog box- as shown in Fig. 7.33,
'l
2 3
lal
4 E 6 7 I s 10
\ 11 12 13 14 tt 1B 17
ta 1$ 20 m 74
,3
2E 26 27 3B ?s 3D 31
mentt bar.
the Internet Explorer window looks like Fig. 7.35 given below. From top to bottom, it contains a
a
Menu bar
Draggable
separator Standard
toolbar
Address bar buttons
;i;iii.r-$D-ry ri
aqq.o, h, fi!{tslt
&,,r{.1d.
:".-.';-"
E{*!{.e;,
iM 7:6
- Viewing
window
Status bar
Fig. 7.35 Internet ExPlorer.
the browser, the
Depending on what you are trying to do and how familiar you are with the vrorkings of
distracting clutter. Forlunately, most of what you see can
elements of the IE window may be either useful tool or
worthwhile. You can display or hide the elements of the IE
be customised to display exactly what you find
window and you can change the amount of space devoted to each element.
Most browser windows have the same basic layout. From top to bottom, you find these basic
elements:
D Menu bar
tr Toolbars
tr Address or Location r.vindow
tr Viewingwindow
B Stdtus bar
a Web page is r-iewed' the
Some Web pages are divided into independent panes, called frames" When such
frame or even move
viewing window issimilarly divided into independent panes. You can scroll up or down in a
from link to link, without disturbing the contents of the other frames.
7.10 Entertainment
The MS-Windows provides facilities to play sound and movies'
For this purpose, Windows have application software called
MediaPlayer as shown inFig.7.36. The Mediaplayercanplay
normal CD audio on a CD-ROM. It also can play other kinds of
)
ts{t
files, such as animation and video files. The Media Player is
simple and intuitive application software.
You can use Media Player to play audio, video, or animation
files and to control the settings for multimedia hardware devices'
Click ',fff to move to the nexr tr ack, or click fi4 to move to the previous
track.
or
Note. Your DVD hardware may require a decoder card and specific software.
Check with your DVD and computer manufacturers for details,
After clicking on RUN, a RUN dialog box will appear as shown in Fig. 7.41 .
.rick I rgr g to
rvn here browse
tv wt vv
drive contents
ir) ii'.ri "
Click this
application to
start
Solved Exercises
Review Questions
(a) Notepad
(b) WordPad
(c) Clipboard
2. Write the difference between Notepad and WordPad.
3. What do you mean by paint ? What will happen when you press the Send option in paint ?
4. Exptain the option Flip and Rotate and Stretch and Skew in windows paint.
5. What is the use of ciraracter map in window ? Which font style character map is more usable in
Windows ?
8.1 lntroduction
Word processing software has,revolutionized the way we create text-based documents. R.ather than committing
each characters to paper as you type - as you would do with a typewriter - word processing enables ycu to
enter documents on screen, edit and format them as you wcrk and save them for future reference or revision.
Nothing appears on paper until you use the Print command.
Toda1,, many word processors are available for use in MS-DOS and MS-Windows. Some of these are :
WordStar, MS-Word, WordPerfect, Windows Write and many more. In this chapter, we shalI learn one such
application package MS-Word, which is used for word processing.
(12e)
130 Saraswatilnformatics practices (Xl)
D We can print whole or part of text.
D We can use special non-printing features to your text.
Also, there are some other features which make MS-Word the most popular word processor.
8.4MS-Office
MS-Office is an integrated software package developed by Microsoft Corporation of USA. Various office
automation activities can be achieved by this package. The MS-Office is GUI software which provides user.-
friendly interaction with applications.
After that, you will see a word document as shown in Fig' 8'2'
6 Formatting toolbar
2 Tab alingment 3 nu bar 5
button
4 Menu bar
5 Stqndard toolbar
6 Formattittg toolbar Contains buttons that you can use for formatting
characters and
paragraphs.
7 Ruler Shorving page width and position of tabs, indents
and columns.
8 Outline view button click this button to view the document outline so that you
can develop
the document's structure.
Print Layout view buttcn click this button to switch print
to Layout view, which shows page borders,
accurate margins, headers and footers and other
elements as tt e!,tt
when you print them.
10 ll/eb Layout view button If you're creating a Web page, click this button
to see how the page wilt
look online.
ll Normal view button Click this button to switch to a normal view of the document.
12 Status bar Shows the current page number and position of
the insertion point in the
document.
13 Mode indicators These show special conditions that are in effect,
such as recordins a
macro, tracking changes in the document, extending
a selection or
overtyping.
14 Scroll bars Use these scroll bars to move the view of the
document up or dou,n or to
quickly jump to a spot in the document. The length
of the vertical scroll
bar represents the length ofthe entire document.
ihe position ofthe scroil
position indicator represents the position in the document
of the currentry
visible window.
8.7 Creating Word Documents
As you know, when you start word, it automatically creates a new document Documentl. So you
straightway start ryping the text. That is, there is -
no need to use any command to first create adocument.
can
you have typed your document, when you save After
it, word will ask for the filename. At that time, you can assign
any filename to Docurnentl and save it in any directory.
The first thing to do is create u n.* io.r.ent. As you've already seen, word
document already disprayed, ready for editing.
opens with a blank
At this poini, you have severar choices :
D You can start working in the blank document that's already open, entering
text and other elements.
when you're ready, you can save the fire as either a
wori document or a web page.
o You can start with one of word's bu ilt-in templates or wizard, which may
already contain some ofthe
text and much of the formatting you need.
a
Tg
n You can create a blank W-eb page or email message.
{j} '*" E ;
i4y Doe,unents
"' f,l ffi -'Touis
Ucer Fites
Ess-i
6ss-3
f,ib&ine l&El
*I
_^J
sd!ts es E/pei
lt,iiord Oor*rnent JJ
O Click anywhere in the Save In drop-down box. A list of available drives ancl resources is displayed
(referFig.8.6).
Word Processing Basics 135
tr Click the drive or resources where you want to store your file. A list of existing documents and foldels
already stored on that drive is displayed.
tr If you want to store your file in one of the subfolders, double-click it; repeat the process until you
arrive at the folder you want.
D Make sure the filename and file format a"re conect, and click Save.
If you've used the file recently, it may appear on the Most Recently tlsed , ii,:';r'- '
file list that appears at the hottorn of the File menu. By default, Word keops track
of the last four files you use; you can reopen one of these files b.y -relecting it
from the File menu. You might want Wbrd to keep track of more than four files.
Word can track up to nine files, though on some computers only seven or eight
may display ileatiy as shown in Fig. 8.9.
To change the number of files Word tracks, choose Tools ) Option, and
click the General tab. In the Recently Used File List scroll box, select the number
of files you Elant to track, from 0 to 9. Ciick Ots. Word begins tracking the new
number of liles.
Ietl*r
Miryosolt lldord t'&itEr
e [aiihsY6$i
St you want to sevx th* ehonqes y*u 3, G:\L19s.{iiildti6r
rn.*d* to lelter?
3 Hr\{la:s.,il{gl*bel
fi* Exr
"_L.,,** ...",".*";
Fig. 8.10 Clnsing an opened file using menu.
Fig. 8.11 Alert message box before closing a file.
Here, click on Yes button.
137
Bscrollbarletyoushiftthecontentsofthedoculnentwindow.
as a certain page"
D The Go To command lets you vielr, a specilic document elernent, such
3 Browse Object buttons lets you browse a document by its elernenrs.
D The Document Map lers you uiove quickly to a specific headin-s.
{al
Thurkutg "vtu
Yoru's silrtrrrly,
$rmit ehcpm
rl ' ,l
rird l F+slate
6Al*',.rh6tr
*rk
tu #,
17 C,rtkee
;{olT:-'in lenee
J Seere te peper sig*l
If you specify individual pages, Word understands hyphens and commas. as in the following examples :
Id$s
Hp LESer -let *.F " Stardard
: Pege r*rrge'
i { gt ;j ,:::
i' r ror,.wr'*s**
i- F,ap:*:
Fig. 8.17 The Print dialog box with Print drop-down list.
8.1 3.5 Printing Thurnbnails
The Page Per Sheet in Zoom option olthe Print dialog box in Fig. 8.17 offers you the opportunity to print
thumbnails of your doclu.leirts - 2. 4, 6, E. or I 5 pages on a single sheet of paper.
Depending on the nuniber of pages you choose. the sizes of your onginal document, and your other
printer settings, Worci vrill arrarge the pages on the sheet to fit as rnany as possible. For instance, if you choose
four pages, Word will print the pages right side. up. one irr each of the sheet's four comers. However, if you print
eight pages, Word will print the pa-9es sidervays on the sheet, in two rows of four pages a piece.
5eaiing
Lerter {8 J,/it I t
Lege{ {8 !i x l{
-. -,. - .ti .- ra ! -2
Fig. 8.18 The Print diaicg box r+4th Scale to paper size option'
To scale a document so ii prints rveLl on another paper size. clispial' the h-int dialog box' Then choose the
Scale to paper size drop-down box in Zoom option of Pnnt dialog box and choose the paper size listed rn the
box.
[n-{*rt
it prtouipur
ABC Psbltc $clrucl,
Dqlht.
I anr a *tlrtlent sf class VII A. In th* first rqeek of f]ee enr]ot' 2{S3, i$y par*nt$ are
gcfurg to attendamarriage fturrticn irr Mr::nbai' fo, I wa:rt a (ve days ieare fram
fr2-lX{,trJz to06-12-2{tr1.
{A
Tlreref*rq I request you, please *llou, nm trr l rirr tha rn*rriage G.urclion with rn3
parpnt$. And grantrae the lravt fsr *i:rve sarcl *ayr.
Tharktrg yau
Fig. 8.21 The PrintPreview screen with selection of Multiple pages icon.
To switch back to a single-page Print Preview, click the One Page button.
Note. You can undo the effects of shnnking if you click the Undo tool; however, after you save the document,
you cannot undo Shrink To Fit.
144 Saraswati lnformatics Practices (X!)
EIE
Paqr i+
Review Questions
9.1 lntroduction
To enter text in a new or existing document, just start typing in the editing wind,rw. If the text doesn't appear,
make sure that Word is the active appiication by clicking anywhere in the Word window.
A blinking vertical line, the itsertion point is displayed in your document at the locati,on where your text
will appear. As you type, your words are placed to the lett of the insertion point as the insertion point moves to
the right. You can move the insertion point by clicking eisewhere in the editing window.
To
The Pdn.iDal
ABC Public $chsol,
Delhi.
most comfortable. If you're an experienced Word user, you already selecttext dozens of times a day. Now might
be a good time to see whether you ban do it mcre efficiently.
(1471
148 Saraswati lnformatics Practices (Xl)
n When vou insert characters, any text to the right of the insertion point shift to the right to make room
for new characters.
fi When you delete text, any teKt to the right of the insertion point shift to the teft to close up space left
by delete characters.
E When you jrsert or dclete text, wcrd r,r,rap adjust if necessary to cointbrtably fit aharacters on gach
line.
9"4.2To DeleteText
D Position the insertion point to the right of the character(s) that you want to delete.
D Press Backspace to delete the character to the left of the insertion point.
,
":i
^$
. i.
Note. You can also delete text by selecting it and pressing Backspace or Delete.
Selected text
Sir"
;.{ 1
Use the Copy, Cut and Paste commands (or their shortcut keys) to place text on the Clipboard
and
tr
then copy it from the Clipboard to another locatron'
D Use drag-and-drop editing to copy or move selected text'
Copying and moving text makes it possible to reuse text and reorganize a document without a lot of
retyping.
The Windows Clipboard is shared among all Windows applications that support the
copy and paste
D
commands.
features,
B The Office Clipboard is shared among all Microsoft Office applications. It offers additional
such as collect and Paste which we discuss later in this chapter.
again
Text copied or cut to the Clipboard remains on the Clipboard until you use the Copy or Cut command
150 Saraswati lnforrnatics Practices (Xl)
or restart your computer. This enables you to use Clipboard contents over and over. These techniques
also
work with objects such as graphics.
9.6.2 To Copy Text with Copy & paste
D Select the text that you want to copy.
tr Choose Edit > Copy as shown in Fig.9.4 or press Ctri+C.
or...
O Click the Copy bunon on the Standard toolbar
The selected text is copied to the clipboard. The document does not change.
D Position the insertion point where you want the text copied"
A Choose Edit > Paste as shown in Fig. 9.4 or press Ctrl+V.
or,
O Click the Paste button on the Standard toolbar.
The text in the Clipboard is copied into the document at the insertion point. Fig. 9.4 Edit Copy option.
9.6.3 To Move Text with Cut & paste
D Select the text that you want to move.
D Choose Edit > Cut as shown in Fig. 9.4 or press Crrl+X.
o!
tr Click the Cut button on the Standard toolbar.
The selected text is copied to the Clipboard and removed from fhe document.
D Position the insertion point where you want the text moved.
D Choose Edit > paste as shown in Fig. 9.d or press
Ctrl+V.
or,
tr Click the Paste button on the Standard toolbar.
The text in the ciipboard is copied into the document at the insertion point.
9.6.4 To Copy Text with Drag-and-Drop Editing
D Select the text that you want to copy.
tr Position the mouse pointer on the selected text.
tr Hold down Ctrl, press the mouse button down and drag. As y'ou drag a tiny box and vertical
line move
with the Inouse pointer, which has a plus sign beside it to indicate that it is copying.
O When the vertical line at the mouse pointer is where you want the text copiea, ietease
the mouse
button and Ctrl. The selected text is copied.
9.6.5 To Move Text with Drag-and-Drop Editing
O Select the text that you want to move.
D Position the mouse pointer on the selected text.
Press Lhe mouse button down and drag. As you clrag, a tiny box and verljcal line
= polnter.
move with the mouse
D When the verlical line at the mouse pointer is rvhere you want the text rnoved, release
the mouse
button. The selected text is moved.
When you first copy text (or anything else) into the Clipboard as shown in Fig. 9.5, Word 2000 works as it
always has: It stores the information in the Clipboard waiting for you to
paste it somewhere. However, if there's already text in the Clipboard, and
you copy more text into the Clipboard, Word 2000 displays the Clipboard
toolbar. ffi
Each time you copy text to the Clipboard, another Word icon appears;
l)
if the text comes from a Web page, a Web page icon appears. The Clipboard
toolbar can hold up to twelve copy blocks. If you attempt to copy a
thirteenth item, Word displays a message wamiug you that it will delete
the oldest of the twelve items currently stored in the Clipboard. Click OK
to continue.
Fig. 9.5 Clipboard toolbar.
tr To paste every Clipboard copy into the document at once, click Paste All.
D To view the text at the beginning of a Clipboard copy, however your mouse pointer over it; the text
appears in a Screen tip.
tr To insert one Clipboard copy; click on its corresponding scrap icon. You can choose any ofthe items
in the Clipboard toolbar, not only the most recent.
tr To empty the Clipboard of all contents, click Clear Clipboard.
D To close the Clipboard toolbar, click Close.
tr Undo reverses your last action. Word supports multiple levels of undo, enabling you to reverse more
than just the very last action.
D Redo reverse the Undo command. This command is only available if the last thing you did was use the
Undo command.
tr Repeat performs your last action again. This command is only available when you performed any
action other than use the Undo or Redo command.
The exact wording of these commands on the Edit menu varies depending on the last action performed.
The Undo command is always the first command under the Edit menu; the Reclo or Repeat command (whichever
appears on the menu) is always the second command under the Edit menu.
The Redo and Repeat commands are never both available at the same time. The Repeat courmand is
especially useful for applying formatting to text scattered throughout your document.
O Click the triangle beside the Undo button ff^.*,on the Standard toolbar
to display a menu of recent actions.
152 Saraswati !nforrnatics Practices (Xi)
rynnnfr i
Drag down to select all the actiilns
that you want to undo. Reiease the
mouse button to undo a[ selected
actrons.
Fig.9.9 Redobutton.
9.8.4 To Reverse Multiple Undos
tr Click Edit ) Redo as shown in Fig. 9.8 or press Ctrl+Y repeatedly.
or,
D Click the triangle beside the Redo button on the Standard tooltrar to display a pop-up menu
of recently undone actions. Drag down to select all the actions that you want to redo. Release the
nouse button to reverse all selected undos.
9.8.5 To Repeat the Last Action
0 Choose Edit > Repeat as shown in Fig. 9. 10 or press Ctrl+Y.
In Word document, you can change the appearance of both the tey,t
chalacters and the paragraphs. Changing the look ofcharacters is font fonnatting @.w'r :S;s*rt lilifgnn*b l
which shows several examples and changing the appearance of paragraphs,
on the other hand, is paragraph formatting which shows a variety of paragraph
formats (refer Fig. 9.11). The most common paragraph formatting changes are
indenting, double spacing, centering,justifying, numbering and adding bullets
to paragraphs.
As r,vith any formatting change, you mustfirst select the text to format (an
individual character, a word or two, a paragraph or the entire document) and
then select either font or paragraph formatting from rnenus, dialog boxes or
Word's toolbars.
For speedy text formatting, font and paragraph formatting can be part of
the information you record in a style. Applying a style that you've created to
a paragraph automatically applies font and paragraph formatting ro that
paragraph.
Fig. 9.10 Repeat feature.
EditingWord Docurrent 153
To
Tln Irineipal
Text with font- ABC Puhlir Srlnol.
AdLibBT, Si Delhi"
$r.
I
I arn asr,lient +f ln the fust n*ri: +il August 2002. r4I Fxelits ar goirig
ro attflrd ameflage flurctionl-F.!(9.-qp_bai S(,. i "tr3*ia fi',rc da3: l"'+ve kora il3 l2
''. |AlJ tc' Ilrl iJ-:0J/
.-{ .t
l'lrrrt l:rt, 1 rrqlest.:ou, l,lrose i!:t, r:i .:E if,r:ir,lr'. t ul: ro?i4
ior:.barrs san da'ysl- Texr wirh RighrAlign
. Fx+tds..p.nd
slpffiI:*tr*l I iil:' :,.' '.r sr. !f .-,\ .. ,f
Fig.9.11 Character and Paragraph formatting.
I am a sfudmet Bf crass XI A In th* irst rvrrk rf August ?Q02, r-rry Iraients e',: going
t0 atte{d a raeniagr fil'ectu:o irt no, I 'llaut * five days itaue &tnr 0t- t i-
2G07 tr Ed-12"2fl03
O Click the arrow button next to the Font Size list on the Formatting toolbar and choose a
different size,
or'
tr Click the curcnt font size on the Formatting toolbar and type a replaoement or!
154 Saraswati lnformatics Practices (Xl)
tr From the Format menu, choose Font as shown in Fig. 9.13, and
rarnxt
,P&
r,, .Slnd+w
then, on the Font tab in the Font dialog box, select a font from the
Font list and a tbnt size from the size list, as shown in Fig. 9.14.
4fllPrrd
tus ('d111
lkerliis E),llrE 8(,ld
I
tvs frleli*Dt
1
t
i
.te-*.sq*h-D"st-Qspjr.U*i*tinrqs T-s:*.v*,t^bF*,itfstI'a'h!Ir,-SslInrt'e
through
If that still isn't enough, you can manufacture a custom color
C$,lrc
you selected in Your document.
Fig 9.16 Font in formatting toolbar'
1&l"ftrls
Tert Elfrcts
F-ig.9.2$ Format
/
158 Saraswati lnformatics Practices (Xl)
TnxtSffr+{s
Te r:r,.rii t }i B I ir;i: it: g B ;rek-gg.:, r"rn,i Tr"o:t with L.as Vegas Ligl*s Eiftci
Fig. 9.23 Word screen with several text effect with the help of Text Effect in Font dialog box tab.
To animate text, select it; press Ctrl+D; choose the Text Effects tab; and choose an animation from the
Animations scroll box. The preview box shows what it will look like.
a shrderrt tf rtass XI A. Iri t.hr first rl,,'eelt crf August f,002" my par*rrts arc
it:g tn afiet:tt a tu.aff1agr frrictinn in #"q4!F.# Eq I rvant a Svt deirs Xearre frr:tn
2- I 2-Zntl3 t* il$-\2"2fr42
remove a drop cap, click the frame, select Format ) Drop Cap and choose None, as shown in Fig' 9'25'
it. wittr-proper formatting, you never need to press Enter in the middle of a paragraph.
jine. For example, a heading of a few words is a paragraph of
Some of the p*ugrupto consist of only one
applies to the
its own, but probably doesn't extend to a second line. A blank line is a paragraph formatting
to have the whole
paragraph as a rvhole. This means that when you apply paragraph fomatting, you don't need
pu.ug.rpt] selected. Clicking to put the insertion point anywhere in the paragraph is all you need'
- ,,rlqr" settings. Although yor, coulcl create a document where every paragraph
Each paragraph can haire
has exactly the same formatting, that need not be the case. In an existing document, You can tell r'vhether some
aspects of paragraph formatting change from paragraph to paragraphs by just watching the ruler'
160
Saraswati lnformatics practices
The ruler displays the indents and tab setting for the
selected paragraphs. As you move to another
paragraph rvith diff-erent settings. the ruler changes.
{?
{f:dentsti*r*
Leh;
c-
Fr*vb*'
The other type of indenting vou'll see - rvhere the first line just out to the
left - is called a hanging indent. Used spanngly, it's gr,rrd way to emphasize the
first few words of a paragraph. (It's also corlmcn for bulleteri and m'.mbered
paragraphs, which are discussed later in this chapterl. To create a hanging
indent, select the paragraphs you want to indent, choose Fonaat F Paragraph
and in the Special box pick Hanging.
Fig. 9.28 Forrnat paragraph option.
*?UI e studeflt of class Xl A lrr fu &'st u,'*k of *ugust 20*2, niy pac*rrts
are going tu attend a rnasna3e fcnetiu: * .$p.m.f""e*i 50. I v,ru:t a fire dayo
leare &r-'rrn i-{2"i3-Z,"l0l t0 i}S"13-7flil2^
Th*reftre" I request y*4 plrase ;llnr," nr* ta i*rn &e rrarriage firnntion witf: rny
parerts. .S"n* grari rnr lhe leere for ahorre earti days.
Fig. 9,29 ll'ord window with difTerent indents.
162 Saraswati !nformatics Practices (Xl)
in Fig. 9.30, you can take a closer look at the ruier and its indent settings.
Hanging indent
Le[t indent
Fig.9.31The Ruler.
To create a new indent using the ruler, first click iu the paragraph you want to change or select multiple
paragraphs. Then drag the upper indent marker to where you want it and release the mouse button.
o Keep Lines together ensures that all the lines of the paragraph appear on a singie page.
page'
O Keep with Next forces Word to put this paragraph and the nexi paragraph on the same
O Page Break Before makes Word start the paragraph on a new page'
164
tr Enter the location where you rvant the tab to appear in the Tab Stop Position text box.
J In the Alignment area, choose the type of tab you want: Left, Center, Rrght, Decimal or Bar.
tr If you want to use a tab leader, select it from the Leader area. You can choose a dot leader. a dash
leader or a solid line leader.
O CLickSet.
A R.epeat steps 1-4 for any additional tabs you wish to set.
tr ClickOK.
Changing Default Tab Stops
As you may recall, Word provides default stops every 0.5" and uses tab stops to determine how far to indent
text when you click the Increase Incient/Decrease Indent buttons on the Formatting tooibar {.or use the equivalent
keyboard shortcuts).
Ycr'.r rnight want to chiinge the default tab stop locations. For example, your document's design might call
for inderrts anci tabs at0.75" increments. To change the ciefault tab stops. choose Format F Tabs as shown in
Fig. 9.33, enter a new value in the Default Tab Stops scroil box, and click OK.
Removing Tabs
You rnay at some point want to remove a tab 1,ou have created manually. To clear all the tab settings in a specific
pat of your document (or in the entire rfticument), select the text or the entire document, choose Format >>
Tabs as shown in Fig. 9.33, then chr:ose Clear All and click OK.
To cleal a specitic tab setting seiect all the paragraphs that contain the tab setting that you want to clear
and drag the tab setting beneath the ruler, so it disappears.
Unfortunately, Word doesn't provide an easy way to know where a tab setting begins and ends in your
doeument, As a result, you may tind eliminating tab settings to be a trial-and-enor process, Here are some tips
that help a lirtlc :
166 Saraswati Inf ormatics Practices (Xl)
o lfall the text you'\'e selected contains the tab setting, the tab setling appears in solid black on your
rrrler.
tr Ifsome ofthe text you've selected contains the tab setting, the tab setting appears in gray on your
ruler. Dragging the tab setting offthe ruler deletes it fol those paragraphs you've selected.
o Ifyou've selected a large number ofparagraphs that starts before you applied the tab setting and end
afterthe tab setting is no longer present, you don't see the tab setting on your ruler evenihough it
is still present in some of the paragraphs you've selected.
Solved Exercises
Ql. l-low will you select the few characters in the docurnents ?
Ans' To select a ferv characters click and drag the cursor across the characters you want to select. you'll notice
that if you drag the cursor across rrore that a couple of words, Word staft to select entire words at a time.
Q2. How will you select the rvhole document ?
Ans. To select the entire document from the edit menu choose the option Select All.
Q3. What is clipboard ?
Ans. Wold has a temporary storage area, called the Clipboard that can be shared alnong all your Windows
applications. When you want to move a paft oftext or graphics ftom one program to another or from one
place in a document to another, you usc the Clipboard. When you cut or copy a selection, it is moved
to
the Clipboard, and it can then be put into another place by pasting.
Q4. What is AutoCorrect ?
Ans. Everybody develops different patterns in his typing. Generally, those patterns include some common
errors. The AutoCorrect fbature allorvs yoLr to tell Word to watch your typing and correct your own
common errors as ),ou type.
Q5. What do you mean by paragraph marks in MS-WORD ?
Ans. 81' dcfault, Word for Windows shows only the text and pictures that will come out of paper when you
print. Special characters such as spaces, tabs and paragraph marks appear as white space in the printed
doculrent. These non-printing characters (so called because they do not appear on pup.. when you
print the document) are often useful to see. This is particularly true when you are working with heavily
formatted documents and need to keep track ofyour tabs, spaces, blank lines, and so on.
Q6. How can you Undo y,our last change ?
Ans. The following steps are used to do Undo your last change :
(a) F'rorn the Edit mentt, choose Undo. The menu shows what your lasi action rvas (for example, Undo
Italic). Or
(b)
Click the Undo button on the Standard loolbar, Or
(c)
Press Ctrl-2.
Q7. FIow can you find special characters in MS-WORD ?
Ans. The following steps are used to find special characters in MS-WORD :
(a) Open the Find dialog box. (Choose Find from the Edit menu)
(6) ClicktheSpecial buttontoseethelistofunusual charactersyoucansearchfor.
(c) Clich the ilfonration you want to find.
Q8. \4t'ite dowu the steps to add a comrnon misspelling of your own to AutoCorrect in MS-WORD.
Ans.(a) From the Tools menu, choose AutoCorrect.
(b) ln the lteplace box, type the rnisspclling that you commonly make. In our example, this would be
standard.
(c) In the With box, type the correct spelling ofthe word. In our exarnple, this would be standard.
(d) ClickttreAddbr"rltou. Sinrilarly,ifyoudon'twanttouseoneoftheiteursinthelist,youcanselectit
ancl click Delete to remove the itern liom the list.
(e) ClickOK.
EditingWord Document 167
I}e Fnnnipal
ABC Fublic Srhool.
l,lD E l(e,+r Drlhi.
Rreperted $ir,
Thrs is to requ*st 1.4* tkat i harre so6e culhyal functiorr irt my home So i vrill no!
he able to atteld rny clasrer from ?flfig|?fi I tl 34/09/200I
Xtrerefore I requ;styou to give rre leave fu tJ:e above merrtiorred days ;urd oblige
1'ouls Cbediently.
Rajat I{apo+r
UIAB5 - V
Ser A
l. Hindi
2. English
3. Mathematics
4. Social Study
5. Geography
6. Science
Select above 6 points and click Bullets button from standard toolbar. Also try to increase the indent using
the standard toolbar button.
14. Do the following :
(a) Open a new word docurnent.
(b) Type the following :
MAPS
A map is a representation of the earth's surface or part of it on a float surfacp_according to a scale. It has
some advantages and disadvantages as comapared to a globe. Maps cannot be as accurate as globes.
Globe is a small model of the earth.
Both are round in shape, so it is quiie easy to show the shapes and sizes ofthe continents and oceans on
the globe quite accurately.
170 Saraswati lnformatics Practices (Xl)
By
Name : Richa Singh
xlA
(c) Center align the heading 'MAPS'. 'u
(d) Justify the whole text. s-
(e) Right Justifl the Name and class.
(fi Indent the first line ofthe paragraph. \
(g) Use the Ruler to indent from left and right.
(ft) Increase the line spacing as double.
(,) Add a drop cap in the begining of the paragraph.
A Use paragraph style and apply style of your choice.
(t) Use page setup to set the top margin and bottom margin as 2". :
(l) Add the page number in the left corner of the document.
I
Chapter 10
10.'! lntroduction
grammar problems in your
Wor.d's spelling and grammar checkers help you to identify potential spelling and
documenis. They can be set to check text automatically as you type or when you have
finished typing'
dictionary, which
The spelling checker compares the words in a document to the words in its main spelling
custom dictionaries
includes over 100,000 words. If it cannot finda match for a word, it then checks the active
flags the word as unknown so you can
- the dictionary files that you create. If word still cannot find a match, it
act on it.
in the document
The grammar checker works in much the same way. It compares the structure of sentences
with a
with predetermined rules fcr a specific writing style. When it finrJs a sentence or sentence fragment
are highly
potential problem, it identifies it for you so you can act on it. Both the spelling and grammar checkers
customizable so they work the way you want them to.
Thanktng ycu
Yrrurs surrerely.
Sumit Chopra
Hsll No 3$
utass - 'J$ JL
error'
Fig. 10.1 Right ctick feature in word document with spelling and Grammar
ng eIT shortcut menu appears'
ut the ices that dePend on the
word Your choices include :
(171)
172
[ffiH::,
word or sentence again as -.:u bv simpry erJiting the text.
vou move yo* inr*ioiffi;;'#:ff'#:',1;,iJHlf; fJ} word
"#;:fffi,-Y:t""::.i:::*:T1:1,
or the sentence now uses coilect
grammar, the corresponding
checks rhe
UH*i:.J:.li;
wavy underline disappears.
't0"2'1 Enabrin!
or Disabling Autonnatic spe*ing
and Grammar ehecking
If you pref'er to use automatic spell checking
or automatic grammar checking,
yoll rvant' you can easily turn as
off or o, or.-o. uotn of them. ir;r.f..+-*;-,,.,v.--,i ,,-,:*,;:.,
El:,:*":,",:",i*{';:i"'ffi;il,iiE.iX.i,n".appearS,clickthe
spelling and Gramrnar tab to '"r 4ppcars, crrcK the
n ^^^Lr^ -
'l-^ -
dispraf i";;;;r. -.:*t: ,: .
I
i
frJffii:fl::?Hi;ilil;":d;:;'illfin.cn".rspe,ringas
or,
:
Fig. 10.4 Options dialog box with Spelling & Gramrnar tatr.
The sentence containing the potential problem appears in the Not in Dictionary scroll box; the incorrect
word appears in red. You now have several options :
D If one of the words shown in the Suggestions list incorrect, click Change; Word changes the spelling
to match that suggestion.
tr If you want Word to change the spelling wherever it appears in the document, click Change All.
174 Saraswati lnformatics Practices (Xl)
D lf you want Word to add the correction to its AutoCorrect database. so Word can fix the error as soon
as you make it llom now on, click AutoCorrect.
D If the word is spelled correctly and you want Word to add it to the custom dictionary (so the word will
never be flagged as wrong again), click Add.
O If Word hasn't made any acceptable suggestions, but you know how to fix the error manually, edit the
word in the Not in Dictionary scroll box, and click Change (or Change Alt or AutoCorect).
1 0.2.3 Spelling Checking Selected Text
Word enables you to check your entire document or any paft of it, including just a single word. [f you don't
want to check your entire docurnent, select only the text you want to check - even if it's just a single word.
You can als6 tell Word to never proof a portion of your document. To do so, select the text you don't want
proofed. Next, choose Tools ) Language, Set Language. The Language diatog box opens. Check the Do Not
Check Spelling or Grammar check box and click OK.
D Always Suggest Corrections. Word's spelling suggestions are often inaccurate in highly technical
documents or documents that contain a lot of arcane jargon. For such documents, to save time, you
might want to disable Word's suggested spellings feature.
O Suggest from Main Dictionary Only. By default, Word looks in all open dictionaries to make
suggestiops about spelling changes. This can take tirne. It also means that Word may recognize as
coffect certain words that are actually incorrect when read in context. lf you're sure your current
document won't benefit fiom words you added to your custom dictionaries, check this box.
tl lgnore Words in UPPERCASE. No spell checker understands all acronyms. Because most acronyms
are all caps, you can tell Word not to flag words that are all caps. (This feature is turned on by default).
O Ignore Words with Numbers. Some product names combine words and numbers.
Suppose that you sell a 486DX2 computer, a24XCD player. Word might flag each of these as
incorrect - a real problem if you're proofing a long price list. Therefore, by default, Word ignores
word/number combinations.
O lgnore Internet and File Addresses. Until recently, most spell checkers have incorrectly flagged
Internet ltle addresses such as the Web address www.yahoo.com or the filename
c:\windows\config.sys. If you leave this check box checked, Word doesn't spell check addresses
such as these.
them with a green wavy underline. To get Word's suggestions, right-click anywhere
in the underlined text'
description of what it thinks is wrong. (refer Fig' 10'7)'
Word displays either potential solutions or a general
If you want to take a closer look at your document's grammar, choose Tools ) Spelling and Grammar or
and Grammar dialog box opens, with the questionable
right click the Grammar tab in shortcut menu. The Spelling
phrase displayed in green.
Word displays possible improvements
inthe Suggestions scroll box. The category
of p:oblem it has identified appears above
Xl A
the ftagged text. Often, none of Word's a sfirdert nl rlass
-S.t.rs.
. i,"r .
t! -t'
Solved Exercises
sent ?
I Menu.
anual spell checking ?
works is
to check
Standard
e spelling check. Click a button to tell
the spell checker
eAll?
ust this one.
u exit Word.
Using Grammar and Spell Check 177
Review Questions
1. How can automatic spelling and gramrnar checking be helpful in Word document ? Explain.
2. Write down the controlling spelling settings in Word.
3. What is a "Style Sheet" in Word ? Discuss its applications.
4. How do lou use Thesaurus in Word ?
5. Do the following :
11.1 lntroduction
Mail merge is the process of creating special type of documents like merged letters, mailing addresses. labels,
envelopes, e/c. These documents have unique information with standard text to create a set of unique documents
- typically, one for every recipient. Word's mail merge feature gives you the power to customize your message
for.lust a few people - or for thousands at the same time. This feature merges fields or categories of database
information with static text to produce merged documents.
Mail merge uses two special kinds of document :
O Main Document. Contains the information that remains the same for each version of the merged
document. In a form letter, for example, the main document would contain the text that appears in
every letter.
fI Data Source Document. Contains the information that changes for each version of merged document.
In a form lettel the data source would contain the names and addresses of the people to receive the
letter. For example, consider a letter. When the postman drops a letter, he just looks the address and
then searches the location to deliver the letter. The address may contain name, address, State, pin-
code, etc., as given below :
(178)
11.3 Create a Master Document
your first step in preparing a mail merge is to create your main document - the document that contains any
which kind of
boilerplate teit that shoulJ appear in all your merged documents, as well as instructions about
information should be merged into them. A main document has tvro components :
that remains
tr Static Text that does not change. In a form letter, for example, static text is the information
the same for each individual who will get the letter. For example, the contents of lettet, etc.
J Mail merge flrelds. These are the variable names generally given to name, address, telephone nurrrber,
should be
etc. whichcan be changed during mail merge. This indicates what data source information
the static text Dear might be
merged into the document and where it should go. In a form letter,
FirstName field are merged
followed by the field <<First Name>>. When merged, the contents of the
into the document after the word Dear to result irt Dear Sidharth, Dear Aakriti, etc.
Dear l\{rs.l$$9.
I hope that your war,J erterirg th* portal +f ihe schoot tarill lnave at as a
respc,tisibie r;itizento sarrre thr tratiol atld huurauity'
Thankrng You,
Principel
ABS Publie School
L4rtguffi :)
ta:-,
1)
l,
Fig. 11.4 The dialog box with options for Active Window or New Main Document.
O If you have already opened the docurnentyou want to use as your main document, click Active
Window; otherwise click New Main Document. After you make your choice, Word
adds a new
button to the Mail Merge Helper : the Edit button.
tr If you are creating a form letter, you can choose the document's name from the Edit rnenu within
the Mail Merge Helper dialog box to add or edit the main document's static
rext.
If you have just created a form letter or a catalog, Word gives you two choices what to
do nert. you can edit
your main document to include the boilerplate text, graphics or other
elements you want to include in it. Or you
can work on creating or choosing your data source.
tr Fields. Fields are categories of information. In a form letter, for example, LastName and Cit;' might be
trvo fields. Each fieid has a unique name, which identifies it in both the main document and data
source document.
tr Records. Records are collections of information for individual items. In a form letter, the Sidharth
record would include all fields for Sidharth - his name, address, city, state and postal code"
11.5 1 To Create a Data Ssurce
Word's Mail Merge Helper can help you wdk
through the process of creating a data source in
Word. Tc create a data source in Word :
D Create a main document as instructed
earlier in this unit. Make it the active
document window.
tr Choose Create Data Source from the
Get Data menu to display the Create
I)ata Source dialog box as shown in
Fig. 1l.5. It lists commonly used fields
names for form letters, mailing labels
and envelopes.
Fig. 11.5 Create data source dialog box.
D Edit the Field names in header row list to include only the field names that you want in your data
source document, in the order that you want them to appear.
D To remove a field name from the list, click to select it, then click the Remove Field Name button.
tr To add a field narne, enter it in the Field name text box, then click the Adri Field Name button,
tr To move a field name up or down in the list, click to select it, then click one of the Move buttons
to the right of the list.
3 When you have finished selecting fields, click OK.
J A Save As dialog box appears. Use it to name and save the data source file.
Note. It's good idea to save the data source file in the same folder in which you have saved or will save the main
docurnent. This makes it easy to find the data source document when merging the main document.
0 A dialog box in Fig. below appears next as shown in Fig. 11.6.
<t
"\
Edll Mairr Dotun:ent
11'TDataFormdialogbox'
11.6.1 To rnseft a Merge Fierd
tr Display the main document. If you have been viewing the data source document, click the Mail
Merge main document button. If necessary, reopen the main document.
o Click to place the insertion point where you want a merge field to appear.
D Click the Insert Merge Field button on the Mail Merge toolbar as shown in Fig. 11.8. Word
displays the merge fields available to your main document. These are the same merge fields that
appear in the data source or heading source document you have chosen.
' : ,\ ..: .J? )
FeS. i laqat Wqr#Fr*i
Each merge field starts and end with chevron symbol : <<>>. You can't insert a merge field from the
keyboard : You have to use the Insert Merge Field button. Place each of your merge fields in the correct
location. Don't forget to include spaces between merge helds if they a'e separate words. And remember the
punctuation that needs to appear in the finished document. Fig. 11.9 shows the letter with attached merge
fields.
Iq,c,uld like to congr.atr.rlatr you or: the sebcii+rr *f your ward nSldarrren rn
d,BS Publie il,:hool, Shalimar P:eCif N-q1y Eelhi He/She ha:: bern allotted
lor s'wit"rrrning corrrg.etriiorr
i hope thai ycur ward errtering the portal oi the schoal wili leave at as a
respctrsrbk citizen tc serve thr narion atrd humanity-
'$r ,;
1' 5e€ I
Fig. 11.9 Letter with attached merge fields.
Before you actually merge, you can preview sample-merged documents on screen by clicking the View
Merged
Data button on the Maii M".g" tootUar in the main document. The merge field names are replaced with the
contents of the first record in the data source as shown in Fig' I 1 ' 1 I '
184
Saraswati lnformatics practices (Xl)
DearLllr.s.rffi., S. K. Ra*at
B-3I3S0, S_4, SECTTIR*?5_?5, RSHII.fl
DBLHI
t1&085
D
I h+pa that your rararel enraring the portal af the scho(,I ruli leare
at a"q a
responsitrln citlrqn to serre the nation anrl htrrnanity.
d ,&-,.d'.a:
Fig. 11.11 Previewing merge document.
r tr iJ ,,r.
CBBlernFoi,Ery
F*x
fn'r€lcFe
Wiz€rd
Frofelsronal
FaX
(te;le ll*r,r
G Duti;,;eni i- trer;Ftr.1:i
Fig. 11.12 New dialog box with LetterS & Faxes tab.
o The Office Assistant appears on the screen as shown in Fig. 1 1 . I 3. If you Wekonre to the
want to create a letter with the help of Mail Merge feature, click the second Letter \Yiaard"
one, otherwise cLick on send one letter. * 5end LrfiB
!etter
5*nci iahiers
tr; o m"-.ilina
hsl
jj
tr Ciick Next, in Step 4 of 4, yctl have Sender Info tab for entering the information about Lhe sender as
shown in Fig. 11.17. Following are the options available in this tab :
d Sender's name
Mail Merge and Word Wizard 187
fr Return address
fi Closings -u[tgr
}..*ul*** u*o ] .oqr", rt*r+idt
.!ai6s 11"6ot.,1,, ."
fl Enclosures
PEinqt
.jnFsrmetien
&ar* 6a pr.sqtrer{rnp.a I*i*r ;.," -.
,.,;;";
The preview box available in this tab shows the
result of your selection. . ?iic$heretq{$s.8d*esrso}h;
. . ffi.:{ . !:i :r,. ,i t.
IBxd*nh fiaE]€;
.Epil.rfi ,*di**ssr
tr- tcqit
Sfurt:61:/,
EaEi.rl
.l.ElftH3$Uret
;n
11.11 UsingTemplate
As yoti have learned in the iast section, awizard asks you intervierv qLrestions
and then produces a fornratted
document that reflects 1'our options and supplied inforrration. A
template, on the other hand, supplies a sample
docurnent with the sb,les and formatting. Flowever, you need to do the
typing yourself.
A Template is a stored file that contains boilerpiate text and/or special formatting
information. lt serves as
a kind of skeleton or blueprint, providing your documents v,rith
an uuderlying structirre. Template also includes
styles, which contain special character and paragraph forrnats.
Word comes with a numbcr of useful templates, each designed fol a specific
kind of document. For
exanrple' the Blanl< dctcument ternplate is used to create a standard
document, while the different styles of memo
template can be used to create a business memo.
The prirmarv benefit of using a template or a wizard is that all or at least
some of the documents characteristics
have been defined in advance. This enables you to create docru.nents that
have similar charaeter and paragraph
fornrats, as well as similar page setups, without havingto speciS, each paranreter
for each document.
in tnost of the templates, you simply select the u,ords you want to replace and type
over them with your
own information. The supplied formatting stal's the same, so you can take arJvantage
of it. These templates
irrclude in their body text instructions for their own use, so even ilyou
don't understand all of the fbrmatting
and features they inciude, you can slili use thern.
'l'ernplates don't necessarill'have
to include sample text. However. r,vhen you first open the New dialog
box, you may notice the B lank Document telnplate under the General
tab. This template (also cailed the Normal
template) doesn't contain any text, only style formatting. The reason
is that when you,re making a new
document, you don't alwal'5 want to staft at with someonselse's text
in it. The normal iemplate lets you start
0ut with a clean state.
11.11.1 Selecting Template for a New Document
When you create a new document using File ) New dialog box, you're
actually choosing a template on which
yout'document r'vill be based. The default Blank Docum"rt t.rnilut.
that most people use is based on Word,s
Normal template, an especially important Word template.
i'\'ord cornes with nearll' 30 ternplates for the documents
you're most likely to create. These temp!ates can
be used to create letters. f-axes, nremos, teports resumes, Web pages,
brochures, manuals and many other
documetlts' To select a template, display the Nerv dialog box, tnen ctict<
thc tab containing the template you
rvant and dcuble-click the tenrpiate.
If you want to save your template in that f.-:lder, so it appears in the General tab of the New dialog box, click
Save. Ifyou want it to appear in a different tab in the New dialog box, double-click that folcler and click Save.
tr Choose File )
New and make sure Blank Document is selected in the General tab.
tr Choose Ternplate from the Create New section in the lower-right corner of the clialog box.
tr ClickOK.
If you follow this procedure to create a template file, you can save the file as a ternplate only, not as a Word
document. Once you've done so, you can add content, styles and other elements and save the finished
template as you would save any other ternplates.
To create a template based on an existing ternplate !
Sometimes you may not have a document that's an adequate model for a template, but Wordjust might. You can
browse thc tabs in the New dialog box to find out. Click on a template. In the Preview box, S'ord displays a
thumbnail sketch of a sample document based on it.
If you find a template you'd iike to use. click Template to indicate that you want to create a new template
rather than a document. Then click OK. A new template open, containing all the contents of V,/ord's builrin
template. Adjust it any way you like and save it under a new name or in a differeni folder.
*qffi
5,d w
Itr ffilHil
i!4iMi;-)"^:- ----
Eleganl Memo Menro'r^ii:erd rl ,?
-}
a :,,i. ;,;,
di: .j-t)
rA)
atr?.;
FJte
e?C, tJ
im a/
l
', !.;
tr Click tlre Organizer button. You see the Organizer dialog box as shown inFig. 11.22.
l" $
t Autofext
':a
a&41''' it
Solved Exercises
Review Questions
1. what is rnail merge ? Explain how can it be used in MS-word by giving an example ?
2. Dehne the use of main document.
3. How can you create a Data Source in MS-Word to do mail merge ?
4. r&'hat do you mean by mailing label ? How can you customize it ?
5. Write dorvn the steps for mail merge.
6. How will you use mailmerge fields ?
7. Write down the steps to change data source.
8. Write down the steps to run the merge.
9. Create two documents as :
(a) A document containing letter for all iliends about Diwali festival.
(6) A data source file containing your best l0 friends' names and addresses.
Try to merge the data source file into the document file as given in this unit. Also take printouts of
all rnerged letters with printer.
10. Write the steps to create a letter through Letter Wizard in Word.
1I. What do you mean by template ? Write down the different ways to create templates.
12. What do you mean by Word organizer ?
13. Do the following :
(a) Use the wizards to create your biodata.
(b) Use templates to send a invitation for the sports competition to DAV public school by your schoot.