You are on page 1of 71

Bank

Management
System
1
A PROJECT REPORT ON
BANK MANAGEMENT SYSTEM
A
DISSERTION SUBMITTED IN PARTIAL FULFILLMENT
OF THE REUIREMENT FOR
DEPARTMENT OF COMMERCE
!"#"
Un$e% s&'e%()s)*n *+
Res,ma Pat)-
S&.m)tte$ By/
S,a)k, M*,amme$ S,*a).
I%s,a$ K,&$a0ant
2
ACKNO1LEDGEMENT
1)t, Can$*% an$ P-eas&%e I take *''*%t&n)ty t*
e2'%ess my s)n3e%e t,anks an$ *.-)gat)*n t* my
esteeme$ g&)$e Res,ma Pat)-4 It )s .e3a&se *+ ,)s
a.-e an$ mat&%e g&)$an3e an$ 3*5*'e%at)*n
0)t,*&t 0,)3, )t 0*&-$ n*t ,a(e .een '*ss).-e +*%
me t* 3*m'-ete my '%*6e3t4
It )s my '-easant $&ty t* t,ank a-- t,e sta++
mem.e% *+ t,e 3*m'&te% 3ente% 0,* ne(e%
,es)tate$ me +%*m t)me $&%)ng t,e '%*6e3t4
F)na--y7 I g%ate+&--y a3kn*0-e$ge t,e s&''*%t7
en3*&%agement 8 'at)en3e *+ my +am)-y7 An$ as
a-0ays7 n*t,)ng )n my -)+e 0*&-$ .e '*ss).-e
0)t,*&t G*$7 T,ank Y*&9
3

CONTENTS
DECLARATION
I ,e%e.y $e3-a%e t,at t,)s '%*6e3t 0*%k t)t-e$
:Bank Management System; )s my *%)g)na- 0*%k
an$ n* 'a%t *+ )t ,as .een s&.m)tte$ +*% nay *t,e%
$eg%ee '&%'*se *% '&.-)s,e$ )n any *t,e% +)%m t)--
$ate4
4

CONTENTS
S.NO. Content

S4N*
#4 P%e+a3e
Int%*$&3t)*n
!4 System St&$y An$ Ana-)sys
!4# System Ana-ys)s
!4! A)m
!4<e2)st)ng System
5

CONTENTS
!4<4# P%*.-ems 1)t, E2)st)ng System
P%*'*se$ System
!4= P%*'*se$ System
!4=4# A$(antages O+ T,e P%*'*se$
System
!4> Feas).)-)ty St&$y


<4 System Des)gn
<4# Int%*$&3t)*n
<4! L*g)3a- Des)gn/
<4< P,ys)3a- Des)gn/
<4<4#$es)gn?S'e3)+)3at)*n A3t)()t)es/
<4= M*$&-e Des)gn
<4=4# A$m)n)st%at)(e M*$&-e
<4=4! C&st*me% M*$&-e
<4> In'&t Des)gn
<4@ O.6e3t)(es
<4A*&t'&t Des)gn
<4B$ata.ase Des)gn
<4B4# Re-at)*na- Data.ase
Management System CR$.msD/
<4B4! Re-at)*ns7 D*ma)ns 8 Att%).&tes/
<4B4< Re-at)*ns,)'s/
<4B4= N*%ma-)Eat)*n/
<4B4B Ta.-es St%&3t&%e
<4F4 System ReG&)%ement
<4F4# Ha%$0a%e ReG&)%ements 8
S*+t0a%e ReG&)%ements
<4F4! S*+t0a%e En()%*nment

=4 C*$)ng An$ F*%ms
>4 System Im'-ementat)*n An$ Test)ng
>4# System Test)ng
>4#4# Test P-an
6
>4#4! Un)t Test)ng
>4#4< Integ%at)*n Test)ng
>4#4= Ha-)$at)*n Test)ng O% System
Test)ng
>4#4> O&t'&t Test)ng O% Use%
A33e'tan3e Test)ng
>4! T%a)n)ng
@4 C*n3-&s)*n
A4 B).-)*g%a',y
B4 On-)ne Re+e%en3e/
PREFACE
Ths s a Pro|ect work undertaken n context of parta
fufment of the Department of computers.
Snce Bank s assocated wth the ves of common
peope and ther day to day routnes so I decded to work
on ths pro|ect.
The manua handng of the record s tme consumng
and hghy prone to error. The purpose of ths pro|ect s
to automate the process of day to day actvtes ke New
Account Openng, Day Transactons, and Modfcaton.
The compete set of rues & procedures reated to
Managng Bakng day to day actvtes and generatng
7
report s caed "BANK MANAGEMENT SYSTEM" .My
pro|ect gvng a bref dea regardng automated bank.
I found t s better to work wth TURBO C++ & ts FILES
facty as database storage. It s qute dffcut to
mantan Database n Turbo C++ nstead the avaabty
of ACCESS & ORACLE etc. havng unque capabty of
handng arge database n effcent manner.
I have tred my best to make the compcated process of
Bank Management System as smpe as possbe usng
Structured & Moduar technque & Menu orented
nterface. I have tred to desgn the software n such a
way that user may not have any dffcuty n usng ths
package & further expanson s possbe wthout much
effort. Even though I cannot cam that ths work to be
entrey exhaustve, the man purpose of my exercse s
perform each Bank actvty n computerzed way rather
than manuay whch s tme consumng.
I am confdent that ths software package can be ready
used by non-programmng persona avodng human
handed chance of error
8
INTRODUCTION
The pro|ect entted "Bank Management System " whch
keep the day by day tay record as a compete bankng
system. It can keep the nformaton of bank customers,
transactons and account nformaton. The exctng part
of ths pro|ect s; t dspays the empoyee detas,
reports and transacton detas.
SYSTEM STUDY AND ANALISYS
!4# SYSTEM ANALYSIS
System anayss s a process of gatherng and
nterpretng facts, dagnosng probems and the
nformaton to recommend mprovements on the system.
It s a probem sovng actvty that requres ntensve
communcaton between the system users and system
9
deveopers. System anayss or study s an mportant
phase of any system deveopment process. The system
s studed to the mnutest deta and anayzed. The
system anayst pays the roe of the nterrogator and
dwes deep nto the workng of the present system. The
system s vewed as a whoe and the nput to the system
are dentfed. The outputs from the organzatons are
traced to the varous processes. System anayss s
concerned wth becomng aware of the probem,
dentfyng the reevant and decsona varabes,
anayzng and syntheszng the varous factors and
determnng an optma or at east a satsfactory souton
or program of acton.
A detaed study of the process must be made by
varous technques ke ntervews, questonnares etc.
The data coected by these sources must be scrutnzed
to arrve to a concuson. The concuson s an
understandng of how the system functons. Ths system
s caed the exstng system. Now the exstng system s
sub|ected to cose study and probem areas are
dentfed. The desgner now functons as a probem
sover and tres to sort out the dffcutes that the
enterprse faces. The soutons are gven as proposas.
The proposa s then weghed wth the exstng system
anaytcay and the best one s seected. The proposa s
presented to the user for an endorsement by the user.
The proposa s revewed on user request and sutabe
changes are made. Ths s oop that ends as soon as the
user s satsfed wth proposa.
Premnary study s the process of gatherng and
nterpretng facts, usng the nformaton for further
studes on the system. Premnary study s probem
sovng actvty that requres ntensve communcaton
between the system users and system deveopers. It
does varous feasbty studes. In these studes a rough
fgure of the system actvtes can be obtaned, from
whch the decson about the strateges to be foowed
for effectve system study and anayss can be taken.
10

!4! AIM
In the exstng system the transactons
are done ony manuay but n proposed system we have
to computerze a the bankng transacton usng ths
software.
They are:
Admnstratve Modue
!4< EIISTING SYSTEM
In the exstng system the transactons are
done ony manuay but n proposed system we have to
computerze a the bankng transacton usng the
software fnanca management system.
!4<4# PROBLEMS 1ITH EIISTING SYSTEM

Lack of securty of data.
More man power.
Tme consumng.
Large voume of paper work.
Needs manua cacuatons.
No drect roe for the hgher offcas.
To avod a these mtatons and make the workng
more accuratey the system needs to be computerzed.
!4= PROPOSED SYSTEM
The am of proposed system s to deveop a system of
mproved factes. The proposed system can overcome
a the mtatons of the exstng system. The system
provdes proper securty and reduces the manua work.
11
!4=4# ADHANTAGES OF THE PROPOSED SYSTEM
The system s very smpe n desgn and to
mpement. The system requres very ow system
resources and the system w work n amost a
confguratons. It has got foowng features
Securty of data.
Ensure data accuracys.
Proper contro of the hgher offcas.
Reduce the damages of the machnes.
Mnmze manua data entry.
Mnmum tme needed for the varous processng.
Greater effcency.
Better servce.
User frendness and nteractve.
Mnmum tme requred.
!4> FEASIBILITY STUDY
Feasbty study s made to see f the pro|ect on
competon w serve the purpose of the organzaton for
the amount of work, effort and the tme that spend on t.
Feasbty study ets the deveoper foresee the future of
the pro|ect and the usefuness. A feasbty study of a
system proposa s accordng to ts workabty, whch s
the mpact on the organzaton, abty to meet ther user
needs and effectve use of resources. Thus when a new
appcaton s proposed t normay goes through a
feasbty study before t s approved for deveopment.
The document provde the feasbty of the pro|ect
that s beng desgned and sts varous areas that were
consdered very carefuy durng the feasbty study of
12
ths pro|ect such as Technca, Economc and Operatona
feasbtes. The foowng are ts features:
TECHNICAL FEASIBILITY
The system must be evauated from the technca
pont of vew frst. The assessment of ths feasbty
must be based on an outne desgn of the system
requrement n the terms of nput, output, programs and
procedures. Havng dentfed an outne system, the
nvestgaton must go on to suggest the type of
equpment, requred method deveopng the system, of
runnng the system once t has been desgned.
Technca ssues rased durng the nvestgaton are:
Does the exstng technoogy suffcent for the suggested
one?
Can the system expand f deveoped?
The pro|ect shoud be deveoped such that the
necessary functons and performance are acheved
wthn the constrants. The pro|ect s deveoped wthn
atest technoogy. Through the technoogy may become
obsoete after some perod of tme, due to the fact that
never verson of same software supports oder versons,
the system may st be used. So there are mnma
constrants nvoved wth ths pro|ect. The system has
been deveoped usng |ava the pro|ect s techncay
feasbe for deveopment.
ECONOMIC FEASIBILITY
13
The deveopng system must be |ustfed by cost and
beneft. Crtera to ensure that effort s concentrated on
pro|ect, whch w gve best, return at the earest. One
of the factors, whch affect the deveopment of a new
system, s the cost t woud requre.

The foowng are some of the mportant fnanca
questons asked durng premnary nvestgaton:
The costs conduct a fu system nvestgaton.
The cost of the hardware and software.
The benefts n the form of reduced costs or fewer
costy errors.
Snce the system s deveoped as part of pro|ect
work, there s no manua cost to spend for the proposed
system. Aso a the resources are aready avaabe, t
gve an ndcaton of the system s economcay possbe
for deveopment.
BEHAHIORAL FEASIBILITY
Ths ncudes the foowng questons:
Is there suffcent support for the users?
W the proposed system cause harm?

The pro|ect woud be benefca because t satsfes
the ob|ectves when deveoped and nstaed. A
behavora aspects are consdered carefuy and
concude that the pro|ect s behavoray feasbe.
14
SYSTEM DESIGN
<4# INTRODUCTION
Desgn s the frst step nto the deveopment phase for
any engneered product or system. Desgn s a creatve
process. A good desgn s the key to effectve system.
The term "desgn" s defned as "the process of appyng
varous technques and prncpes for the purpose of
defnng a process or a system n suffcent deta to
permt ts physca reazaton". It may be defned as a
process of appyng varous technques and prncpes for
the purpose of defnng a devce, a process or a system
n suffcent deta to permt ts physca reazaton.
Software desgn sts at the technca kerne of the
software engneerng process and s apped regardess
of the deveopment paradgm that s used. The system
desgn deveops the archtectura deta requred to bud
a system or product. As n the case of any systematc
approach, ths software too has undergone the best
possbe desgn phase fne tunng a effcency,
performance and accuracy eves. The desgn phase s a
transton from a user orented document to a document
to the programmers or database personne. System
desgn goes through two phases of deveopment: Logca
and Physca Desgn.
<4! LOGICAL DESIGN/
The ogca fow of a system and defne the
boundares of a system. It ncudes the foowng steps:
15
Revews the current physca system - ts data
fows, fe content, voumes, frequences etc.
Prepares output specfcatons - that s, determnes
the format, content and frequency of reports.
Prepares nput specfcatons - format, content and
most of the nput functons.
Prepares edt, securty and contro specfcatons.
Specfes the mpementaton pan.
Prepares a ogca desgn wak through of the
nformaton fow, output, nput, contros and
mpementaton pan.
Revews benefts, costs, target dates and system
constrants.
<4< PHYSICAL DESIGN/
Physca system produces the workng systems by
defne the desgn specfcatons that te the
programmers exacty what the canddate system must
do. It ncudes the foowng steps.
Desgn the physca system.
Specfy nput and output meda.
Desgn the database and specfy backup
procedures.
Desgn physca nformaton fow through the
system and a physca desgn Wak through.
Pan system mpementaton.
Prepare a converson schedue and target date.
Determne tranng procedures, courses and
tmetabe.
Devse a test and mpementaton pan and specfy
any new hardware/software.
Update benefts , costs , converson date and
system constrants
<4<4# Des)gn?S'e3)+)3at)*n a3t)()t)es/
16
Concept formuaton.
Probem understandng.
Hgh eve requrements proposas.
Feasbty study.
Requrements engneerng.
Archtectura desgn.
<4= MODULE DESIGN
<4=4# ADMINISTRATIHE MODULE
Ths modue s the man modue whch
performs a the man operatons n the system. The
ma|or operatons n the system are:
Admn ogn
Add/Deete/Update Customers
Wthdrawa/depost Transacton
Creatng new Account (Savng Account, Recurrng
Account, Current Accounts)
Searchng account nformaton/Transacton
nformaton
Report generaton
Settngs
<4=4! CUSTOMER MODULE
17
Ths modue s the man modue whch
performs some specfc operatons n the system. The
operatons n the system are:
Customer ogn
Searchng account nformaton/Transacton
nformaton
Reports


<4> INPUT DESIGN
The desgn of nput focuses on controng the amount
of nput requred, controng the errors, avodng deay,
avodng extra steps and keepng the process smpe.
The nput s desgned n such a way so that t provdes
securty and ease of use wth retanng the prvacy. Input
Desgn consdered the foowng thngs:
1,at $ata s,*&-$ .e g)(en as )n'&tJ
H*0 t,e $ata s,*&-$ .e a%%ange$ *% 3*$e$J
T,e $)a-*g t* g&)$e t,e *'e%at)ng 'e%s*nne- )n
'%*()$)ng )n'&t4
Met,*$s +*% '%e'a%)ng )n'&t (a-)$at)*ns an$
ste's t* +*--*0 0,en e%%*% *33&%4
<4@ OBJECTIHES
Input Desgn s the process of convertng a user-orented
descrpton of the nput nto a computer-based system.
Ths desgn s mportant to avod errors n the data nput
process and show the correct drecton to the
management for gettng correct nformaton from the
computerzed system.
18
It s acheved by creatng user-frendy screens for the
data entry to hande arge voume of data. The goa of
desgnng nput s to make data entry easer and to be
free from errors. The data entry screen s desgned n
such a way that a the data manpuates can be
performed. It aso provdes record vewng factes.
When the data s entered t w check for ts vadty.
Data can be entered wth the hep of screens.
Approprate messages are provded as when needed so
that the user w not be n maze of nstant. Thus the
ob|ectve of nput desgn s to create an nput ayout that
s easy to foow
<4A OUTPUT DESIGN

A quaty output s one, whch meets the
requrements of the end user and presents the
nformaton ceary. In output desgn t s determned
how the nformaton s to be dspaced for mmedate
need and aso the hard copy output. It s the most
mportant and drect source nformaton to the user.
Effcent and ntegent output desgn mproves the
systems reatonshp to hep user decson-makng.
Desgnng computer output shoud proceed n an
organzed, we thought out manner; the rght output
must be deveoped whe ensurng that each output
eement s desgned so that peope w fnd the system
can use easy and effectvey. When anayss desgns
computer output, they shoud:
Identfy the specfc output that s needed to meet
the requrements.
Seect methods for presentng nformaton.
Create document, report, or other formats that
contan nformaton produced by the system.

<4B DATABASE DESIGN
19
A database s an organzed mechansm that has the
capabty of storng nformaton through whch a user
can retreve stored nformaton n an effectve and
effcent manner. The data s the purpose of any
database and must be protected.
The database desgn s a two eve process. In the
frst step, user requrements are gathered together and
a database s desgned whch w meet these
requrements as ceary as possbe. Ths step s caed
Informaton Leve Desgn and t s taken ndependent of
any ndvdua DBMS.
In the second step, ths Informaton eve desgn s
transferred nto a desgn for the specfc DBMS that w
be used to mpement the system n queston. Ths step
s caed Physca Leve Desgn, concerned wth the
characterstcs of the specfc DBMS that w be used. A
database desgn runs parae wth the system desgn.
The organzaton of the data n the database s amed to
acheve the foowng two ma|or ob|ectves.
Data Integrty
Data ndependence
Normazaton s the process of decomposng the
attrbutes n an appcaton, whch resuts n a set of
tabes wth very smpe structure. The purpose of
normazaton s to make tabes as smpe as possbe.
Normazaton s carred out n ths system for the
foowng reasons.
To structure the data so that there s no repetton
of data , ths heps n savng.
To permt smpe retreva of data n response to
query and report request.
To smpfy the mantenance of the data through
updates, nsertons, deetons.
20
To reduce the need to restructure or reorganze
data whch new appcaton requrements arse.
<4B4# RELATIONAL DATABASE MANAGEMENT
SYSTEM CRDBMSD/
A reatona mode represents the database as a
coecton of reatons. Each reaton resembes a tabe of
vaues or fe of records. In forma reatona mode
termnoogy, a row s caed a tupe, a coumn header s
caed an attrbute and the tabe s caed a reaton. A
reatona database conssts of a coecton of tabes,
each of whch s assgned a unque name. A row n a tae
represents a set of reated vaues.
<4B4! RELATIONS7 DOMAINS 8 ATTRIBUTES/
A tabe s a reaton. The rows n a tabe are caed
tupes. A tupe s an ordered set of n eements. Coumns
are referred to as attrbutes. Reatonshps have been set
between every tabe n the database. Ths ensures both
Referenta and Entty Reatonshp Integrty. A doman D
s a set of atomc vaues. A common method of
specfyng a doman s to specfy a data type from whch
the data vaues formng the doman are drawn. It s aso
usefu to specfy a name for the doman to hep n
nterpretng ts vaues. Every vaue n a reaton s
atomc, that s not decomposabe.
<4B4< RELATIONSHIPS/
Tabe reatonshps are estabshed usng Key. The
two man keys of prme mportance are Prmary Key &
Foregn Key. Entty Integrty and Referenta Integrty
Reatonshps can be estabshed wth these keys. Entty
Integrty enforces that no Prmary Key can have nu
21
vaues. Referenta Integrty enforces that no Prmary
Key can have nu vaues.
Referenta Integrty for each dstnct Foregn Key vaue,
there must exst a matchng Prmary Key vaue n the
same doman. Other key are Super Key and Canddate
Keys.
Reatonshps have been set between every tabe n the
database. Ths ensures both Referenta and Entty
Reatonshp Integrty.
<4B4= NORMALIKATION/
As the name mpes, t denoted puttng thngs n the
norma form. The appcaton deveoper va
normazaton tres to acheve a sensbe organzaton of
data nto proper tabes and coumns and where names
can be easy correated to the data by the user.
Normazaton emnates repeatng groups at data and
thereby avods data redundancy whch proves to be a
great burden on the computer resources. These ncude:
Normaze the data.
Choose proper names for the tabes and coumns.
Choose the proper name for the data.
F)%st N*%ma- F*%m :
The Frst Norma Form states that the doman of an
attrbute must ncude ony atomc vaues and that the
vaue of any attrbute n a tupe must be a snge vaue
from the doman of that attrbute. In other words 1NF
dsaows "reatons wthn reatons" or "reatons as
attrbute vaues wthn tupes". The ony attrbute vaues
permtted by 1NF are snge atomc or ndvsbe vaues.
22
The frst step s to put the data nto Frst Norma
Form. Ths can be donor by movng data nto separate
tabes where the data s of smar type n each tabe.
Each tabe s gven a Prmary Key or Foregn Key as per
requrement of the pro|ect. In ths we form new reatons
for each nonatomc attrbute or nested reaton. Ths
emnated repeatng groups of data.
A reaton s sad to be n frst norma form f ony f t
satsfes the constrants that contan the prmary key
ony.
Se3*n$ N*%ma- F*%m :
Accordng to Second Norma Form, for reatons
where prmary key contans mutpe attrbutes, no
nonkey attrbute shoud be functonay dependent on a
part of the prmary key.
In ths we decompose and setup a new reaton for
each parta key wth ts dependent attrbutes. Make sure
to keep a reaton wth the orgna prmary key and any
attrbutes that are fuy functonay dependent on t. Ths
step heps n takng out data that s ony dependant on
apart of the key.
A reaton s sad to be n second norma form f and
ony f t satsfes a the frst norma form condtons for
the prmary key and every non-prmary key attrbutes of
the reaton s fuy dependent on ts prmary key aone.
T,)%$ N*%ma- F*%m :
Accordng to Thrd Norma Form, Reaton shoud not
have a nonkey attrbute functonay determned by
another nonkey attrbute or by a set of nonkey
attrbutes. That s, there shoud be no transtve
dependency on the prmary key.
23
In ths we decompose and set up reaton that
ncudes the nonkey attrbutes that functonay
determnes other nonkey attrbutes. Ths step s taken to
get rd of anythng that does not depend entrey on the
Prmary Key.
A reaton s sad to be n thrd norma form f ony f t
s n second norma form and more over the non key
attrbutes of the reaton shoud not be depend on other
non key attrbute.
<4B4B TABLES STRUCTURE
Tabe: ogn
Prmary Key: username
F)e-$ Data Ty'e C*nst%a)nts Des3%)'t)*n
Username Char(15) Prmary key
Password Number(9)
Rghts Char(10)
Tabe: empoyee
Prmary Key: emp d
F)e-$ Data Ty'e C*nst%a)nts Des3%)'t)*n
Emp no Number(9) Prmary key
Empoyee
name
char(30)
Address char(30)
24
Cty Char(30)
State char(30)
Country Char(30)
Pncode number
Phone1 number
Phone2 number
Fax Char(30)
<4F SYSTEM REUIREMENT

<4F4# HARD1ARE REUIREMENTS
Processor : X86 Compatbe processor wth 1.7 GHz
Cock speed
RAM : 512 MB or more
Hard dsk: 20 GB or more
Montor : VGA/SVGA
Keyboard : 104 Keys
Mouse : 2 buttons/ 3 buttons
<4F4! SOFT1ARE REUIREMENTS
Operatng System : Wndows 2000/XP
Front end : Vsua Basc 6.0
Back end : MS Access
25
<4F4< SOFT1ARE ENHIRONMENT
T,e C*nt%*- P%*'e%t)es
Before wrtng an event procedure for the contro to
response to a user's nput, you have to set certan
propertes for the contro to determne ts appearance
and how t w work wth the event procedure. You can
set the propertes of the contros n the propertes
wndow or at runtme.
Han$-)ng s*me *+ t,e 3*mm*n 3*nt%*-s
T,e Te2t B*2
The text box s the standard contro for acceptng nput
from the user as we as to dspay the output. It can
hande strng (text) and numerc data but not mages or
pctures. Strng n a text box can be converted to a
numerc data by usng the functon Va(text). The
foowng exampe ustrates a smpe program that
processes the nput from the user.
E2am'-e
In ths program, two text boxes are nserted nto the
form together wth a few abes. The two text boxes are
used to accept nputs from the user and one of the
abes w be used to dspay the sum of two numbers
that are entered nto the two text boxes. Besdes, a
command button s aso programmed to cacuate the
sum of the two numbers usng the pus operator. The
program use creates a varabe sum to accept the
summaton of vaues from text box 1 and text box 2.The
procedure to cacuate and to dspay the output on the
abe s shown beow. The output s shown n Fgure 3.2
Prvate Sub Command1_Cck()
To add the vaues n text box 1 and text box 2
Sum = Va(Text1.Text) + Va(Text2.Text)
26
To dspay the answer on abe 1
Labe1.Capton = Sum
End Sub
F)g&%e <4!

T,e La.e-
The abe s a very usefu contro for Vsua Basc, as t s
not ony used to provde nstructons and gudes to the
users, t can aso be used to dspay outputs. One of ts
most mportant propertes s Ca't)*n. Usng the syntax
-a.e-4Ca't)*n, t can dspay text and numerc data .
You can change ts capton n the propertes wndow and
aso at runtme. Pease refer to Exampe 3.1 and Fgure
3.1 for the usage of abe.
T,e C*mman$ B&tt*n

The command button s one of the most mportant
contros as t s used to execute commands. It dspays
an uson that the button s pressed when the user cck
on t. The most common event assocated wth the
command button s the Cck event, and the syntax for
the procedure s
Prvate Sub Command1_Cck ()
Statements
27
End Sub
T,e P)3t&%e B*2
The Pcture Box s one of the contros that s used to
hande graphcs. You can oad a pcture at desgn phase
by cckng on the pcture tem n the propertes wndow
and seect the pcture from the seected foder. You can
aso oad the pcture at runtme usng the L*a$P)3t&%e
method. For exampe, the statement w oad the pcture
grape.gf nto the pcture box.
Pcture1.Pcture=LoadPcture ("C:\VB
program\Images\grape.gf")
You w earn more about the pcture box n future
essons. The mage n the pcture box s not reszabe.

T,e Image B*2
The Image Box s another contro that handes mages
and pctures. It functons amost dentcay to the pcture
box. However, there s one ma|or dfference, the mage
n an Image Box s stretchabe, whch means t can be
reszed. Ths feature s not avaabe n the Pcture Box.
Smar to the Pcture Box, t can aso use the LoadPcture
method to oad the pcture. For exampe, the statement
oads the pcture grape.gf nto the mage box.
Image1.Pcture=LoadPcture ("C:\VB
program\Images\grape.gf")
T,e C*m.* B*2

The functon of the Combo Box s aso to present a st of
tems where the user can cck and seect the tems from
the st. However, the user needs to cck on the sma
arrowhead on the rght of the combo box to see the
tems whch are presented n a drop-down st. In order
28
to add tems to the st, you can aso use the A$$Item
met,*$. For exampe, f you wsh to add a number of
tems to Combo box 1, you can key n the foowng
statements
E2am'-e
Prvate Sub Form_Load ( )
Combo1.AddItem "Item1"
Combo1.AddItem "Item2"
Combo1.AddItem "Item3"
Combo1.AddItem "Item4"
End Sub

T,e C,e3k B*2

The Check Box contro ets the user seects or unseects
an opton. When the Check Box s checked, ts vaue s
set to 1 and when t s unchecked, the vaue s set to 0.
You can ncude the statements Check1.Vaue=1 to
mark the Check Box and Check1.Vaue=0 to unmark the
Check Box, as we as use them to ntate certan
actons. For exampe, the program w change the
background coor of the form to red when the check box
s unchecked and t w change to bue when the check
box s checked. You w earn about the condtona
statement If..Then..Eesf n ater esson. VbRed and
vbBue are coor constants and BackCoor s the
background coor property of the form.
T,e O't)*n B*2

The Opton Box contro aso ets the user seects one of
the choces. However, two or more Opton Boxes must
work together because as one of the Opton Boxes s
seected, the other Opton Boxes w be unseected. In
fact, ony one Opton Box can be seected at one tme.
When an opton box s seected, ts vaue s set to "True"
and when t s unseected; ts vaue s set to "Fase". In
29
the foowng exampe, the shape contro s paced n the
form together wth sx Opton Boxes. When the user
ccks on dfferent opton boxes, dfferent shapes w
appear. The vaues of the shape contro are 0, 1, and
2,3,4,5 whch w make t appear as a rectange, a
square, an ova shape, a rounded rectange and a
rounded square respectvey.
E2am'-e
Prvate Sub Opton1_Cck ( )
Shape1.Shape = 0
End Sub
Prvate Sub Opton2_Cck()
Shape1.Shape = 1
End Sub
Prvate Sub Opton3_Cck()
Shape1.Shape = 2
End Sub
Prvate Sub Opton4_Cck()
Shape1.Shape = 3
End Sub
Prvate Sub Opton5_Cck()
Shape1.Shape = 4
End Sub
Prvate Sub Opton6_Cck()
Shape1.Shape = 5
End Sub

30
CODING AND FORMS
M*$&-e C*$)ng
#4 M*$&-e#
Pubc cnBank As Connecton
Pubc rsCustomers As Recordset
Pubc rsDepost As Recordset
Pubc rsWthdrawa As Recordset
Pubc rsAccTypes As Recordset
Pubc ogn As Recordset
Pubc rsTemp As Recordset
Pubc rsTemp2 As Recordset
Pubc x As Integer
Pubc dance, customer As Integer
Pubc Sub create_navgaton_buttons(frm As Form)
Wth frm
Wth .cmdOptons(0)
.Pcture = LoadPcture(App.Path &
"\pctures\n1.|pg")
.DsabedPcture = LoadPcture(App.Path &
"\pctures\nd1.|pg")
End Wth
For = 1 To 4
Load .cmdOptons()
Wth .cmdOptons()
.Vsbe = True
.Left = frm.cmdOptons( - 1).Left +
frm.cmdOptons( - 1).Wdth + 25
.Pcture = LoadPcture(App.Path &
"\pctures\n" & ( + 1) & ".|pg")
.DsabedPcture = LoadPcture(App.Path &
"\pctures\nd" & ( + 1) & ".|pg")
End Wth
Next
31

.cmdNavgate(0).Pcture = LoadPcture(App.Path &
"\pctures\n6.|pg")
For = 1 To 3
Load .cmdNavgate()
Wth .cmdNavgate()
.Vsbe = True
.Left = frm.cmdNavgate( - 1).Left +
frm.cmdNavgate( - 1).Wdth + 15
.Pcture = LoadPcture(App.Path &
"\pctures\n" & ( + 6) & ".|pg")
End Wth
Next
.cmdOptons(1).Enabed = Fase:
.cmdOptons(2).Enabed = Fase
End Wth
End Sub
Pubc Sub create_countres(combobx As ComboBox)
Dm st() As Strng
Dm st2 As Strng
Dm As Integer
st2 = "Unted
Kngdom\Abana\Argentna\Afghanstan\Agera\Austraa
\Begum\Braz\Chna\Canada\Coomba\Costa
Rca\Czech
Repubc\Germany\Denmark\Egypt\Ecuador\Unted Arab
Emrates\Fnand\France\Greece\Hong
Kong\Hungary\Indonesa\Ireand\Inda\Israe\Itay\|apan\L
ebanon\Maaysa\Mexco\Netherands\Norway\New
Zeaand\Austra\Phppnes\Pakstan\Poand\Portuga\Per
u\Puerto Rco\Russa\Saud
Araba\Sweden\Span\Sngapore\Swtzerand\Thaand\Tu
rkey\Tawan\Ta|kstan\Tanzana\Tunsa\Tuvau\Unted
States of Amerca\Ukrane\Venezuea\South
Afrca\Uganda\Uzbekstan\Vatcan
Cty\Vetnam\Yemen\Zmbabwe"
st = Spt(st2, "\")
32
For = LBound(st) To UBound(st)
combobx.AddItem (st())
Next
combobx.LstIndex = 25
End Sub
Pubc Sub connectDatabase()
Set cnBank = New ADODB.Connecton

Wth cnBank
.Provder = "Mcrosoft.|ET.OLEDB.4.0"
.ConnectonStrng = App.Path & "\dbBank.mdb"
.Open
End Wth

Set rsCustomers = New ADODB.Recordset
rsCustomers.Open "tbCustomers", cnBank,
adOpenKeyset, adLockOptmstc

Set rsDepost = New ADODB.Recordset
rsDepost.Open "tbDeposts", cnBank, adOpenKeyset,
adLockOptmstc

Set rsWthdrawa = New ADODB.Recordset
rsWthdrawa.Open "tbWthdrawas", cnBank,
adOpenKeyset, adLockOptmstc

Set rsAccTypes = New ADODB.Recordset
rsAccTypes.Open "tbAccTypes", cnBank,
adOpenKeyset, adLockOptmstc


End Sub
Pubc Sub cear_Form_Contros(frm As Form)
Dm ctr As Contro
For Each ctr In frm.Contros
If TypeOf ctr Is TextBox Then
33
ctr.Text = ""
EseIf TypeOf ctr Is ComboBox Then
ctr.Text = ""
End If
Next ctr
End Sub
Pubc Sub Messager()
MsgBox "Pease Ensure that a feds are Compete",
vbExcamaton
End Sub
Pubc Sub Lock_Form_Contros(frm As Form)
Dm ctr As Contro
For Each ctr In frm.Contros
If TypeOf ctr Is TextBox Then
ctr.Locked = True
EseIf TypeOf ctr Is ComboBox Then
ctr.Locked = True
EseIf TypeOf ctr Is DTPcker Then
ctr.Enabed = Fase
End If
Next ctr
End Sub
Pubc Sub UnLock_Form_Contros(frm As Form)
Dm ctr As Contro
For Each ctr In frm.Contros
If TypeOf ctr Is TextBox Then
ctr.Locked = Fase
EseIf TypeOf ctr Is ComboBox Then
ctr.Locked = Fase
EseIf TypeOf ctr Is DTPcker Then
ctr.Enabed = True
End If
Next ctr
End Sub
Pubc Sub MoveToFrst(rsFrst As Recordset)
Wth rsFrst
Ca CheckDatabaseStatus(rsFrst)
34
.MoveFrst
If .BOF Then
.MoveFrst
MsgBox "Ths s the frst Record..", vbInformaton
Ext Sub
End If
End Wth
End Sub
Pubc Sub MoveToPrev(rsPrev As Recordset)
Wth rsPrev
Ca CheckDatabaseStatus(rsPrev)
.MovePrevous
If .BOF Then
.MoveFrst
MsgBox "Ths s the frst Record..", vbInformaton
Ext Sub
End If
End Wth
End Sub
Pubc Sub MoveToNext(rsNext As Recordset)
Wth rsNext
Ca CheckDatabaseStatus(rsNext)
.MoveNext
If .EOF Then
.MoveLast
MsgBox "Ths s the ast Record..", vbInformaton
Ext Sub
End If
End Wth
End Sub
Pubc Sub MoveToLast(rsLast As Recordset)
Wth rsLast
Ca CheckDatabaseStatus(rsLast)
.MoveLast
If .EOF Then
.MoveLast
MsgBox "Ths s the ast Record..", vbInformaton
35
Ext Sub
End If
End Wth
End Sub
Pubc Sub CheckDatabaseStatus(rsStat As Recordset)
Wth rsStat
If .BOF = True And .EOF = True Then
MsgBox "There are currenty No records
Avaabe for ths modue", vbInformaton
Ext Sub
End If
End Wth
End Sub
Pubc Sub Shoab() 'add
dance = 1
End Sub
Pubc Sub Irshad() 'edt
dance = 2
End Sub
Pubc Sub outmsg() 'save
If dance = 1 Then
MsgBox ("Account Is Created"), vbInformaton
EseIf dance = 2 Then
MsgBox ("Account Update Successfu "), vbInformaton
End If
dance = 0
End Sub
Pubc Functon dhanno() As Integer
dhanno = customer
customer = 1
End Functon
Pubc Sub custo()
customer = 1
End Sub
36
L*g)n F*%m
!4 +%mL*g)n
Prvate Sub cmdCance_Cck()
End
End Sub
Prvate Sub cmdOK_Cck()
Dm str1 As Strng
str1 = user.Text

Set cnBank1 = New ADODB.Connecton
Wth cnBank1
.Provder = "Mcrosoft.|ET.OLEDB.4.0"
.ConnectonStrng = App.Path & "\dbBank.mdb"
.Open
End Wth
Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * from tbLogn", cnBank1,
adOpenKeyset, adLockOptmstc
If rsTemp.RecordCount > 0 Then
If str1 = "Admn" Then
If rsTemp(4) = user.Text And rsTemp(5) =
pass.Text Then
rsTemp.Cose
37
MsgBox ("Access granted")
MDIForm1.Show
Me.Hde
Ext Sub
Ese
MsgBox "Invad User Name or Password Pease
Try Agan", vbCrtca
rsTemp.Cose
End
End If
End If
If str1 = "customer" Then
rsTemp.MoveNext
If rsTemp(4) = user.Text And rsTemp(5) =
pass.Text Then
rsTemp.Cose
Ca custo
MsgBox ("Access granted")
MDIForm1.Show
Me.Hde
Ext Sub
Ese
MsgBox "Invad User Name or Password Pease
Try Agan", vbCrtca
rsTemp.Cose
End

End If
End If

MsgBox "Invad User Name or Password Pease Try
Agan", vbCrtca
rsTemp.Cose
End
End If



38
End Sub
Prvate Sub Form_Load()
Me.Heght = 3390
Me.Wdth = 4050
End Sub

Ma)n F*%m
<4 MDIF*%m#
Dm customer As Integer
Dm chkstatus As Integer
Prvate Sub Cmdmenu_Cck(Index As Integer)
Seect Case Index

Case 0: frmCustomers.Show
Case 1: frmDeposts.Show
Case 2: frmWthdrawa.Show
Case 3: frmTransactons.Show
Case 4: frmReports.Show
Case 5: frmSettngs.Show
Case 6: frmsearch.Show
Case Is = 7
If (MsgBox("Are You Sure To Ext?", vbYesNo,
"Bank System")) = vbYes Then
End
End If



End Seect
39
End Sub
Prvate Sub MDIForm_Load()
x = dhanno
If x = 1 Then
Cmdmenu(0).Pcture = LoadPcture(App.Path &
"\pctures\1.|pg")
For = 1 To 7
Load Cmdmenu()
Cmdmenu().Vsbe = True
Cmdmenu().Left = Cmdmenu( - 1).Left +
Cmdmenu( - 1).Wdth + 500
Cmdmenu().Pcture = LoadPcture(App.Path &
"\pctures\" & ( + 1) & ".|pg")
Next
Cmdmenu(0).Enabed = Fase
Cmdmenu(0).Enabed = Fase
Cmdmenu(1).Enabed = Fase
Cmdmenu(2).Enabed = Fase
Cmdmenu(5).Enabed = Fase

Ese
Cmdmenu(0).Pcture = LoadPcture(App.Path &
"\pctures\1.|pg")
For = 1 To 7
Load Cmdmenu()
Cmdmenu().Vsbe = True
Cmdmenu().Left = Cmdmenu( - 1).Left +
Cmdmenu( - 1).Wdth + 500
Cmdmenu().Pcture = LoadPcture(App.Path &
"\pctures\" & ( + 1) & ".|pg")
Next
End If
Me.Pcture = LoadPcture(App.Path &
"\pctures\background.|pg")
End Sub
40
De'*s)t F*%m
=4 +%mDe'*s)t
Dm currBaance As Currency
Prvate Sub cboCustomerNo_Cck()
Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * FROM tbCustomers WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
Wth rsTemp
If .RecordCount > 0 Then
txtDeposts(1).Text = !AccountNo
txtDeposts(2).SetFocus
Ese
MsgBox "Invad Customer Code", vbInformaton
txtDeposts(1).Text = ""
Ext Sub
End If
.Cose
End Wth

Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * FROM tbCustomers WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
41
If rsTemp.RecordCount > 0 Then
bBaance.Capton = rsTemp(13)
Ese
Ext Sub
End If
rsTemp.Cose
End Sub
Prvate Sub cmdOptons_Cck(Index As Integer)
Dm As Integer
Seect Case Index
Case Is = 0
If cboCustomerNo.Text = "" Then
Ca Messager
cboCustomerNo.SetFocus
Ext Sub
End If

If txtDeposts(1).Text = "" Then
MsgBox "Pease Enter the Customer Correcty.",
vbInformaton
cboCustomerNo.SetFocus
Ext Sub
End If

For = 0 To 5
If txtDeposts().Text = "" Then
Ca Messager
txtDeposts().SetFocus
Ext Sub
End If
Next
currBaance = (CCur(bBaance.Capton) +
CCur(txtDeposts(3).Text))
= 0
For x = 0 To 7
42
Seect Case x
Case Is = 1
rsDepost(x) = cboCustomerNo.Text
Case Is = 7
rsDepost(x) = txtDated.Vaue
Case Ese
rsDepost(x) = txtDeposts().Text
= + 1
End Seect
Next x
rsDepost(8) = currBaance
rsDepost.Update


Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * FROM tbCustomers WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
If rsTemp.RecordCount > 0 Then
rsTemp(13) = currBaance
Ese
Ext Sub
End If
rsTemp.Update
rsTemp.Cose

Set rsTemp1 = New ADODB.Recordset
rsTemp1.Open "Seect * FROM tbDeposts WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
If rsTemp1.RecordCount > 0 Then
rsTemp1(8) = currBaance
Ese
Ext Sub
End If
rsTemp1.Update
rsTemp1.Cose

43
MsgBox "Amount Deposted Pease Check Your
Baance", vbInformaton
x = txtDeposts(0).Text
If (DataEnvronment1.rsCommand1.State = 1) Then
DataEnvronment1.rsCommand1.Cose
Ese
DataEnvronment1.Command1 (x)
Load rptdeposts
rptdeposts.Show
End If
Case Is = 1
rsDepost.CanceUpdate
End Seect
Unoad Me

End Sub
Prvate Sub Form_Load()
Wth cmdOptons(0)
.Pcture = LoadPcture(App.Path &
"\pctures\fdepo.|pg")
End Wth
For = 1 To 1
Load cmdOptons()
Wth cmdOptons()
.Vsbe = True
.Left = cmdOptons( - 1).Left + cmdOptons( -
1).Wdth + 25
If = 1 Then
.Pcture = LoadPcture(App.Path &
"\pctures\n3.|pg")
Ese
.Pcture = LoadPcture(App.Path &
"\pctures\n10.|pg")
End If
End Wth
Next
txtDated = Date
44
Ca connectDatabase

For x = 1 To rsCustomers.RecordCount
cboCustomerNo.AddItem rsCustomers(0)
rsCustomers.MoveNext
Next x
Ca cear_Form_Contros(Me)
Ca GenerateNewTransactCode
rsDepost.AddNew
End Sub
Pubc Sub GenerateNewTransactCode()
Dm astnumber As Long, newnumber As Long
If rsDepost.BOF = True And rsDepost.EOF = True
Then
astnumber = 1000
Ese
rsDepost.MoveLast
astnumber = rsDepost(0)
End If
newnumber = astnumber + 1
txtDeposts(0).Text = newnumber
End Sub
Prvate Sub optCash_Cck(Index As Integer)
Seect Case Index
Case Is = 0
txtDeposts(5).Text = "N/A"
txtDeposts(5).Locked = True
txtDeposts(4).Text = "CASH"
txtDeposts(4).Locked = True
Case Is = 1
txtDeposts(4).Text = "CHEOUE"
txtDeposts(4).Locked = True
txtDeposts(5).Text = ""
txtDeposts(5).Locked = Fase
txtDeposts(5).SetFocus
Case Is = 2
45
txtDeposts(4).Locked = Fase
txtDeposts(4).SetFocus
txtDeposts(4).Text = ""
txtDeposts(5).Text = "N/A"
txtDeposts(5).Locked = True
End Seect
End Sub
Prvate Sub txtDeposts_LostFocus(Index As Integer)
If Index = 3 Then
If IsNumerc(txtDeposts(3).Text) = Fase And Not
(txtDeposts(3).Text = "") Then
MsgBox "Invad Input", vbOKOny + vbCrtca,
"Error"
txtDeposts(3).Text = ""
txtDeposts(3).SetFocus
End If
End If
End Sub
1)t,$%a0a-s F*%m
>4+%m1)t,$%a0a-s
Prvate Sub cmdOptons_Cck(Index As Integer)
Dm As Integer
Seect Case Index
Case Is = 0
If cboCustomerNo.Text = "" Then
Ca Messager
cboCustomerNo.SetFocus
Ext Sub
End If
If txtDeposts(1).Text = "" Then
46
MsgBox "Pease Enter the Customer Correcty.",
vbInformaton
cboCustomerNo.SetFocus
Ext Sub
End If

For = 0 To 3
If txtDeposts().Text = "" Then
Ca Messager
txtDeposts().SetFocus
Ext Sub
End If
Next
If (Va(bBaance.Capton) -
Va(txtDeposts(3).Text)) < Va(Labe3.Capton) Then
MsgBox "Money cant be wthdrawn as the
account baance has reached mnmum!"
Ext Sub
End If
= 0
For x = 0 To 5
Seect Case x
Case Is = 1
rsWthdrawa(x) = cboCustomerNo.Text
Case Is = 5
rsWthdrawa(x) = txtDated.Vaue
Case Ese
rsWthdrawa(x) = txtDeposts().Text
= + 1
End Seect
Next x
rsWthdrawa(6) = Va(bBaance.Capton) -
Va(txtDeposts(3).Text)
rsWthdrawa.Update

Set rsTemp = New ADODB.Recordset
47
rsTemp.Open "Seect * FROM tbCustomers WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
If rsTemp.RecordCount > 0 Then
rsTemp(13) = Va(bBaance.Capton) -
Va(txtDeposts(3).Text)
Ese
Ext Sub
End If
rsTemp.Update
rsTemp.Cose
MsgBox ("Amount Wthdraw Succesfuy"),
vbInformaton
x = txtDeposts(0).Text
If (DataEnvronment1.rsCommand4.State = 1) Then
DataEnvronment1.rsCommand4.Cose
Ese
DataEnvronment1.Command4 (x)
Load rptwthdrawas
rptwthdrawas.Show
End If


Case Is = 1
rsDepost.CanceUpdate
End Seect
Unoad Me
End Sub
Prvate Sub Form_Load()
Wth cmdOptons(0)
.Pcture = LoadPcture(App.Path &
"\pctures\fwth.|pg")
End Wth
For = 1 To 1
Load cmdOptons()
Wth cmdOptons()
.Vsbe = True
48
.Left = cmdOptons( - 1).Left + cmdOptons( -
1).Wdth + 25
If = 1 Then
.Pcture = LoadPcture(App.Path &
"\pctures\n3.|pg")
Ese
.Pcture = LoadPcture(App.Path &
"\pctures\n10.|pg")
End If
End Wth
Next
txtDated = Date
Ca connectDatabase

For x = 1 To rsCustomers.RecordCount
cboCustomerNo.AddItem rsCustomers(0)
rsCustomers.MoveNext
Next x

Ca cear_Form_Contros(Me)
Ca GenerateNewTransactCode
rsWthdrawa.AddNew
End Sub
Pubc Sub GenerateNewTransactCode()
Dm astnumber As Long, newnumber As Long
If rsWthdrawa.BOF = True And rsWthdrawa.EOF =
True Then
astnumber = 15000
Ese
rsWthdrawa.MoveLast
astnumber = rsWthdrawa(0)
End If
newnumber = astnumber + 1
txtDeposts(0).Text = newnumber
End Sub
Prvate Sub cboCustomerNo_Cck()
Set rsTemp = New ADODB.Recordset
Set rsTemp2 = New ADODB.Recordset
49
rsTemp.Open "Seect * FROM tbCustomers WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
Wth rsTemp
If .RecordCount > 0 Then
txtDeposts(1).Text = !AccountNo
txtDeposts(2).SetFocus
Ese
MsgBox "Invad Customer Code", vbInformaton
txtDeposts(1).Text = ""
Ext Sub
End If
.Cose
End Wth

Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * FROM tbCustomers WHERE
CustomerID='" & cboCustomerNo.Text & "'", cnBank,
adOpenKeyset, adLockOptmstc
If rsTemp.RecordCount > 0 Then
bBaance.Capton = rsTemp(13)
Ese
Ext Sub
End If

rsTemp2.Open "Seect * FROM tbAccTypes WHERE
AccountName='" & rsTemp(12) & "'", cnBank,
adOpenKeyset, adLockOptmstc
Labe3.Capton = rsTemp2(4)
rsTemp2.Cose
rsTemp.Cose
End Sub
T%ansa3t)*n Statements F*%m
50
@4 +%mT%ansa3t)*ns
Dm stItem As LstItem
Prvate Sub Command1_Cck()
If fnd_tran("tbWthdrawas Where Dated BETWEEN
#" & dtFrom.Vaue & "# AND #" & dtTo.Vaue & "#",
MSFexGrd1, 1) = Fase And fnd_tran("tbDeposts
Where Dated BETWEEN #" & dtFrom.Vaue & "# AND #"
& dtTo.Vaue & "#", MSFexGrd2, 2) = Fase Then
MsgBox "No Transacton found. Pease Try Agan",
vbInformaton
End If
End Sub
Prvate Sub set_dat(qr As Strng)
Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * from " & qr, cnBank,
adOpenKeyset, adLockOptmstc
Wth rsTemp
If .RecordCount > 0 Then
cboAccNo = !AccountNo
cboCustomerID = !CustomerID
cboFrst = !FrstName
Ese
MsgBox "Invad customer ID/Name/Account NO.
Pease Try Agan", vbInformaton
Ext Sub
End If
.Cose
End Wth
If fnd_tran("tbWthdrawas Where AccountNo='" &
cboAccNo.Text & "'", MSFexGrd1, 1) = Fase And
fnd_tran("tbDeposts Where AccountNo='" &
cboAccNo.Text & "'", MSFexGrd2, 2) = Fase Then
MsgBox "No Transacton found. Pease Try Agan",
vbInformaton
End If
End Sub
51
Prvate Sub cboCustomerID_Cck()
Ca set_dat("tbCustomers Where CustomerID='" &
cboCustomerID.Text & "'")
End Sub
Prvate Sub cboCustomerID_KeyPress(KeyAsc As
Integer)
If KeyAsc = 13 Then Ca cboCustomerID_Cck
End Sub
Prvate Sub cboFrst_Cck()
Ca set_dat("tbCustomers Where FrstName='" &
cboFrst.Text & "'")
End Sub
Prvate Sub cboAccNo_Cck()
Ca set_dat("tbCustomers Where AccountNo='" &
cboAccNo.Text & "'")
End Sub
Functon fnd_tran(tb As Strng, MSFex As MSFexGrd,
pu As Integer) As Booean
Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * from " & tb, cnBank,
adOpenKeyset, adLockOptmstc
MSFex.Cear
If pu = 1 Then
Ca create_wth(rsTemp)
Ese
Ca create_dep(rsTemp)
End If
Wth rsTemp
If .RecordCount > 0 Then
Ca LoadLstVew(rsTemp, MSFex)
Ese
fnd_tran = Fase
Ext Functon
End If
52
.Cose
End Wth
fnd_tran = True
End Functon
Prvate Sub cboAccNo_KeyPress(KeyAsc As Integer)
If KeyAsc = 13 Then Ca cboAccNo_Cck
End Sub
Prvate Sub cboFrst_KeyPress(KeyAsc As Integer)
If KeyAsc = 13 Then Ca cboFrst_Cck
End Sub
Prvate Sub Form_Load()
Opton1(1).Vaue = True
Frame1.Enabed = Fase
Frame2.Enabed = Fase
Ca connectDatabase
Ca create_wth(rsWthdrawa)
Ca LoadLstVew(rsWthdrawa, MSFexGrd1)
Ca create_dep(rsDepost)
Ca LoadLstVew(rsDepost, MSFexGrd2)
Wth rsCustomers
.MoveFrst
For X = 1 To .RecordCount
cboCustomerID.AddItem !CustomerID
cboFrst.AddItem !FrstName
cboAccNo.AddItem !AccountNo
.MoveNext
Next X
End Wth
Frame1.Enabed = Fase
End Sub
Prvate Sub Opton1_Cck(Index As Integer)
If Index = 0 Then
Frame1.Enabed = True
Frame2.Enabed = True
53
Ese
Frame1.Enabed = Fase
Frame2.Enabed = Fase
If fnd_tran("tbWthdrawas", MSFexGrd1, 1) =
Fase And fnd_tran("tbDeposts", MSFexGrd2, 2) =
Fase Then
MsgBox "No Transacton found.", vbInformaton
End If
cboAccNo.Text = "Seect..."
cboCustomerID.Text = "Seect..."
cboFrst.Text = "Seect..."
End If
End Sub
Pubc Sub create_dep(rs As Recordset)
Wth MSFexGrd2
.Rows = rs.RecordCount + 1
.Cos = 8
.Row = 0:
.Co = 0: .Text = "TransactonID"
.Co = 1: .Text = "CustomerID"
.Co = 2: .Text = "AccountNo"
.Co = 3: .Text = "Narraton"
.Co = 4: .Text = "AmountDeposted"
.Co = 5: .Text = "Mode"
.Co = 6: .Text = "CheckNo"
.Co = 7: .Text = "Dated"
End Wth
End Sub
Pubc Sub create_wth(rs As Recordset)
Wth MSFexGrd1
.Rows = rs.RecordCount + 1
.Cos = 6
.Row = 0
.Co = 0: .Text = "TransactonID"
.Co = 1: .Text = "CustomerID"
.Co = 2: .Text = "AccountNo"
.Co = 3: .Text = "Narraton"
.Co = 4: .Text = "AmountWthdrawn"
54
.Co = 5: .Text = "Dated"
End Wth
End Sub
Pubc Sub LoadLstVew(myrs As Recordset, MSFex As
MSFexGrd)
MSFex.Rows = myrs.RecordCount + 1
MSFex.Row = 0
Wth myrs
Whe Not .EOF
MSFex.Row = MSFex.Row + 1
For = 0 To .Feds.Count - 1
MSFex.Co =
MSFex.Text = .Feds.Item()
Next
.MoveNext
Wend
End Wth
End Sub
Sett)ngs F*%m
A4 +%mSett)ngs
'frmSettngs
Pubc rsSettngs As Recordset
Prvate Sub cmdNavgate_Cck(Index As Integer)
Seect Case Index
Case Is = 0 'Move Frst
Ca MoveToFrst(rsAccTypes)
Ca DspayCustomers(rsAccTypes)
Case Is = 1 'Move Prevous
Ca MoveToPrev(rsAccTypes)
Ca DspayCustomers(rsAccTypes)
Case Is = 2 'Move Next
55
Ca MoveToNext(rsAccTypes)
Ca DspayCustomers(rsAccTypes)
Case Is = 3 'Move Last
Ca MoveToLast(rsAccTypes)
Ca DspayCustomers(rsAccTypes)
End Seect
End Sub
Pubc Sub DspayCustomers(myrs As Recordset)
For = 7 To 11: Text1().Text = myrs( - 7): Next
End Sub
Prvate Sub cmdOptons_Cck(Index As Integer)
Seect Case Index
Case Is = 0 'Add
For = 0 To 4: cmdOptons().Enabed = Fase:
Next
cmdOptons(1).Enabed = True:
cmdOptons(2).Enabed = True
Ca UnLock_Form_Contros(Me)
Ca cear_Form_Contros(Me)
rsAccTypes.AddNew
Case Is = 1 'Save
For = 7 To 11
If Text1().Text = "" Then Ca Messager
Next

For = 7 To 11
rsAccTypes( - 7) = Text1().Text
Next

For = 0 To 4: cmdOptons().Enabed = True:
Next
cmdOptons(1).Enabed = Fase:
cmdOptons(2).Enabed = Fase
Ca Lock_Form_Contros(Me)

Case Is = 2 'Cance
56
rsAccTypes.CanceUpdate
For = 0 To 4: cmdOptons().Enabed = True:
Next
cmdOptons(1).Enabed = Fase:
cmdOptons(2).Enabed = Fase

Ca DspayCustomers(rsAccTypes)
Ca Lock_Form_Contros(Me)

Case Is = 3 'Edt
For = 0 To 4: cmdOptons().Enabed = Fase:
Next
cmdOptons(1).Enabed = True:
cmdOptons(2).Enabed = True
Ca UnLock_Form_Contros(Me)

Case Is = 4 'Deete
If (MsgBox("Sure To Deete?", vbYesNo +
vbOueston, "Confrm Deete")) = vbYes Then
Wth rsAccTypes
If .BOF = True And .EOF = True Then
MsgBox "Nothng to deete",
vbInformaton
Ext Sub
End If
.Deete
Ca cear_Form_Contros(Me)
.MoveFrst
Ca DspayCustomers(rsAccTypes)
End Wth
Ca Lock_Form_Contros(Me)
End If
End Seect
End Sub
Prvate Sub Form_Load()
Ca create_navgaton_buttons(Me)
57
pcLogo.Pcture = LoadPcture(App.Path &
"\pctures\ogo.|pg")
Ca create_countres(Combo1)
Ca connectDatabase

Set rsSettngs = New ADODB.Recordset
rsSettngs.Open "tbSettngs", cnBank, adOpenKeyset,
adLockOptmstc
Ca Lock_Form_Contros(Me)
Ca DspayCustomers(rsAccTypes)
End Sub
Prvate Sub pcLogo_DbCck()
Wth daog
.DaogTte = "Choose the Pcture"
.FeName = ""
On Error GoTo e
.ShowOpen
If .FeName = "" Then Ext Sub
End Wth

pcLogo.Pcture = LoadPcture(daog.FeName)
FeCopy daog.FeName, App.Path &
"\pctures\ogo.|pg"
e:
If Err.Number <> 0 Then MsgBox Err.Descrpton
End Sub
Prvate Sub SSTab1_Cck(PrevousTab As Integer)
If PrevousTab = 1 Then
For = 0 To 6
If < 6 Then Text1().Text = rsSettngs()
If = 6 Then
Combo1.Text = rsSettngs()
Text1().Text = rsSettngs( + 1)
End If
Next
Ca UnLock_Form_Contros(Me)
58
Ese
For = 0 To 6
If < 6 Then rsSettngs() = Text1().Text
If = 6 Then
rsSettngs() = Combo1.Text
rsSettngs( + 1) = Text1().Text
End If
Next
rsSettngs.Update
End If
End Sub
Re'*%t F*%m
B4 +%mRe'*%ts
Prvate Sub Command1_Cck()
For = 0 To 2
If Opton1().Vaue = True Then Ext For
Next
Seect Case
Case Is = 0
DataReport3.Show
Case Is = 1
AccountDetas.Show
Case Is = 2
frmTransactons.Show
End Seect
Unoad Me
End Sub
59
Prvate Sub Form_Load()
Command1.Pcture = LoadPcture(App.Path &
"\pctures\n10.|pg")
End Sub
Sea%3, F*%m
F4 +%msea%3,
Prvate Sub searchc(qr As Strng)
Set cnBank1 = New ADODB.Connecton

Wth cnBank1
.Provder = "Mcrosoft.|ET.OLEDB.4.0"
.ConnectonStrng = App.Path & "\dbBank.mdb"
.Open
End Wth
Set rsTemp = New ADODB.Recordset
rsTemp.Open "Seect * from " & qr, cnBank1,
adOpenKeyset, adLockOptmstc
Wth rsTemp
If .RecordCount > 0 Then
cus = !CustomerID
fr = !FrstName
60
as = !LastName
con = !ContactTte
nat = !IDNO
dat = !Date|oned
acc = !AccountType
ope = !Baance
add = !Address
pos = !PostaCode
oc = !Locaton
pho = !PhoneNo
ema = !Ema
Ese
MsgBox "Invad customer Account NO. Pease
Try Agan", vbInformaton
Ext Sub
End If
.Cose
End Wth



End Sub
Prvate Sub cmdOptons_Cck(Index As Integer)
Ca searchc("tbCustomers Where AccountNo='" &
search.Text & "'")
End Sub
Prvate Sub Form_Load()
Me.Heght = 7000
Me.Wdth = 7140
End Sub

E2)t
61

>4 SYSTEM IMPLEMENTATION AND TESTING
Impementaton s the stage of the pro|ect where the
theoretca desgn s turned nto a workng system. It can
be consdered to be the most cruca stage n achevng a
successfu new system ganng the users confdence that
the new system w work and w be effectve and
accurate. It s prmary concerned wth user tranng and
documentaton. Converson usuay takes pace about
the same tme the user s beng traned or ater.
Impementaton smpy means convenng a new system
desgn nto operaton, whch s the process of convertng
a new revsed system desgn nto an operatona one.
>4#4 SYSTEM TESTING
62
Software Testng s the process of executng software
n a controed manner, n order to answer the queston -
Does the software behave as specfed?. Software testng
s often used n assocaton wth the terms verfcaton
and vadaton. Vadaton s the checkng or testng of
tems, ncudes software, for conformance and
consstency wth an assocated specfcaton. Software
testng s |ust one knd of verfcaton, whch aso uses
technques such as revews, anayss, nspectons, and
wakthroughs. Vadaton s the process of checkng that
what has been specfed s what the user actuay
wanted.
Vadaton / Are we dong the rght |ob?
Verfcaton / Are we dong the |ob rght?
Software testng shoud not be confused wth
debuggng. Debuggng s the process of anayzng and
ocazng bugs when software does not behave as
expected. Athough the dentfcaton of some bugs w
be obvous from payng wth the software, a methodca
approach to software testng s a much more thorough
means for dentfyng bugs. Debuggng s therefore an
actvty whch supports testng, but cannot repace
testng.
Other actvtes whch are often assocated wth software
testng are statc anayss and dynamc anayss. Statc
anayss nvestgates the source code of software,
ookng for probems and gatherng metrcs wthout
actuay executng the code. Dynamc anayss
ooks at the behavor of software whe t s executng, to
provde nformaton such as executon traces, tmng
profes, and test coverage nformaton.
Testng s a set of actvty that can be panned n
advanced and conducted systematcay. Testng begns
at the modue eve and work towards the ntegraton of
63
entre computers based system. Nothng s compete
wthout testng, as t vta success of the system testng
ob|ectves, there are severa rues that can serve as
testng ob|ectves. They are

Testng s a process of executng a program wth the
ntend of fndng an error.A good test case s one that
has hgh possbty of fndng an undscovered error.A
successfu test s one that uncovers an undscovered
error.

If a testng s conducted successfuy accordng to the
ob|ectves as stated above, t woud uncovered errors n
the software aso testng demonstrate that the software
functon appear to be workng accordng to the
specfcaton, that performance requrement appear to
have been met.

There are three ways to test program.
For correctness
For mpementaton effcency
For computatona compexty

Test for correctness are supposed to verfy that a
program does exacty what t was desgned to do. Ths s
much more dffcut than t may at frst appear,
especay for arge programs.
>4#4# TEST PLAN
A test pan mpes a seres of desred course of acton
to be foowed n accompshng varous testng methods.
The Test Pan acts as a bue prnt for the acton that s to
be foowed. The software engneers create a computer
program, ts documentaton and reated data structures.
64
The software deveopers s aways responsbe for testng
the ndvdua unts of the programs, ensurng that each
performs the functon for whch t was desgned. There s
an ndependent test group (ITG) whch s to remove the
nherent probems assocated wth ettng the buder to
test the thng that has been but. The specfc ob|ectves
of testng shoud be stated n measurabe terms. So that
the mean tme to faure, the cost to fnd and fx the
defects, remanng defect densty or frequency of
occurrence and test work-hours per regresson test a
shoud be stated wthn the test pan.
The eves of testng ncude:
Unt testng
Integraton Testng
Data vadaton Testng
Output Testng
>4#4! UNIT TESTING
Unt testng focuses verfcaton effort on the smaest
unt of software desgn - the software component or
modue. Usng the component eve desgn descrpton as
a gude, mportant contro paths are tested to uncover
errors wthn the boundary of the modue. The reatve
compexty of tests and uncovered scope estabshed for
unt testng. The unt testng s whte-box orented, and
step can be conducted n parae for mutpe
components. The moduar nterface s tested to ensure
that nformaton propery fows nto and out of the
program unt under test. The oca data structure s
examned to ensure that data stored temporary
mantans ts ntegrty durng a steps n an agorthms
executon. Boundary condtons are tested to ensure that
a statements n a modue have been executed at east
once. Fnay, a error handng paths are tested.
65
Tests of data fow across a modue nterface are
requred before any other test s ntated. If data do not
enter and ext propery, a other tests are moot.
Seectve testng of executon paths s an essenta task
durng the unt test. Good desgn dctates that error
condtons be antcpated and error handng paths set
up to reroute or ceany termnate processng when an
error does occur. Boundary testng s the ast task of unt
testng step. Software often fas at ts boundares.
Unt testng was done n Se-Soft System by treatng
each modue as separate entty and testng each one of
them wth a wde spectrum of test nputs. Some faws n
the nterna ogc of the modues were found and were
rectfed.
>4#4< INTEGRATION TESTING
Integraton testng s systematc technque for
constructng the program structure whe at the same
tme conductng tests to uncover errors assocated wth
nterfacng. The ob|ectve s to take unt tested
components and bud a program structure that has
been dctated by desgn. The entre program s tested as
whoe. Correcton s dffcut because soaton of causes
s compcated by vast expanse of entre program. Once
these errors are corrected, new ones appear and the
process contnues n a seemngy endess oop.
After unt testng n Se-Soft System a the modues
were ntegrated to test for any nconsstences n the
nterfaces. Moreover dfferences n program structures
were removed and a unque program structure was
evoved.
>4#4= HALIDATION TESTING OR SYSTEM TESTING
66
Ths s the fna step n testng. In ths the entre
system was tested as a whoe wth a forms, code,
modues and cass modues. Ths form of testng s
popuary known as Back Box testng or System testng.
Back Box testng method focuses on the functona
requrements of the software. That s, Back Box testng
enabes the software engneer to derve sets of nput
condtons that w fuy exercse a functona
requrements for a program.
Back Box testng attempts to fnd errors n the
foowng categores; ncorrect or mssng functons,
nterface errors, errors n data structures or externa
data access, performance errors and ntazaton errors
and termnaton errors.
>4#4> OUTPUT TESTING OR USER ACCEPTANCE
TESTING
The system consdered s tested for user acceptance;
here t shoud satsfy the frms need. The software
shoud keep n touch wth perspectve system; user at
the tme of deveopng and makng changes whenever
requred. Ths done wth respect to the foowng ponts
Input Screen Desgns,
Output Screen Desgns,
Onne message to gude the user and the ke.
The above testng s done takng varous knds of test
data. Preparaton of test data pays a vta roe n the
system testng. After preparng the test data, the system
under study s tested usng that test data. Whe testng
the system by whch test data errors are agan
uncovered and corrected by usng above testng steps
and correctons are aso noted for future use.
>4! TRAINING
67
Once the system s successfuy deveoped the next
mportant step s to ensure that the admnstrators are
we traned to hande the system. Ths s because the
success of a system nvaraby depends on how they are
operated and used. The mpementaton depends upon
the rght peope beng at the rght pace at the rght
tme. Educaton nvoves creatng the rght atmosphere
and motvatng the user. The admnstrators are
famarzed wth the run procedures of the system,
workng through the sequence of actvtes on an
ongong bass.
Impementaton s the state n the pro|ect where the
theoretca desgn s turned nto a workng system. By
ths, the users get the confdence that the system w
work effectvey. The system can be mpemented ony
after through testng.
The systems personne check the feasbty of the
system. The actua data were nputted to the system
and the workng of the system was cosey montored.
The master opton was seected from the man menu
and the actua data were nput through the
correspondng nput screens. The data movement was
studed and found to be correct queres opton was then
seected and ths contans varous reports. Uttes
provde varous data needed for nventory was nput and
the modue was test run. Satsfactory resuts were
obtaned. Reports reated to these processes were aso
successfuy generated. Varous nput screen formats are
sted n the appendx.
Impementaton wakthroughs ensure that the
competed system actuay soves the orgna probem.
Ths wakthrough occurs |ust before the system goes nto
use, and t shoud ncude carefu revew of a manuas,
tranng materas and system documentaton. Agan,
68
users, the anayst and the members of the computer
servces staff may attend ths meetng.


CONCLUSION
"Bank Management System " keeps the day by day tay
record as a compete bankng system. It can keep the
nformaton of bank empoyee, transactons, oan
souton, ATM nformaton and account nformaton. The
exctng part of ths pro|ect s; t dspays the empoyee
detas, payment detas, oan detas and transacton
detas.
69
BIBLIOGRAPHY
BOOKS:
1. Software Engneerng
2. Informaton Technoogy by Sumta Aurora (CBSE
2007)
3. Vsua Basc 6.0
ONLINE REFERENCE/
www.w3schoos.com
70
www.theserversde.com
www.vsua.com
71

You might also like