Académique Documents
Professionnel Documents
Culture Documents
ON
BANKING MANAGEMENT SYSTEM
COURSE: - B.TECH.
SUBMITTED BY:-
YEAR: - 2009-10
Neha Bansal(0701910041)
Evangeline Kharlyngdoh(0701910021)
BONAFIDE CERTIFICATE
GS MANDALS
Who carried out the project work under my supervision, towards partial
fulfillment of the requirements of the Degree of Bachelor of Technology
in Computer Science & Engineering from Uttar Pradesh Technical
University, Lucknow.
SUPERVISOR (Lecturer)
Engineering
Engineering
Marathwada Institute Of
Marathwada Institute Of
Technology,
Technology,
Bulandshahr.
Bulandshahr.
CERTIFICATE OF AUTHENTICATION
We solemnly declare that this project report on Banking Management System is
the bonafide work done purely by us, carried out under the supervision of Mr.
Achal Agarwal, towards partial fulfillment of the requirements of the Degree of
Bachelor of Technology in Computer Science & Engineering from Uttar Pradesh
Technical University, Lucknow during the year 20092010.
It is further certified that this work has not been submitted, either in part of in full, to
any other department of the UPTU, or any other University, institution or elsewhere,
or for publication in any form.
NAME
Neha Bansal
ROLL NO.
-
Evangeline Kharlyngdoh -
0701910041
0701910021
ACKNOWLEDGEMENT
INDEX
i. Introduction to Banking Management System.
ii. Objectives.
iii. Importance
iv. H/W and S/W Requirements.
v. System analysis.
vi. System design.
vii. Input design
viii. Output design
ix. Test plan
x. Maintenance
xi. Functions
xii. Introduction to C
xiii. MS access.
xiv. Database Structure
xv. Module description
xvi. ER diagram.
xvii. Snapshots
xviii. Conclusion
xix. Coding.
xx. Bibliography.
INTRODUCTION :
AIM:To develop a software for solving financial applications of a
customer in banking environment in order to nurture the needs of
an end banking user by providing various ways to perform banking
tasks. Also to enable the users workspace to have additional
functionalities which are not provided under a conventional
banking software.
This System is developed to solve the problem of the Bankers who are unable to
keep record of thousands of customers and their transactions.Easy to create new
account of customer, up to date account informationProvide easily deposit and
withdrawal of money. A little overview of this system is given below:How it helps in Banking Management: This software provides a database to store huge amount of data.
All the data related to the banking transactions can be move simply.
How it is useful for customers also: This banking management software saves customers costly time.
On spot updation in account directories takes place which is very excellent
features.
Is it safe: The whole information stored in the database is safe because it is used locally
in particular bank and not spread out over the Internet.
The whole data is the password protected which prevents unauthorized access
to the database.
Benefits:
It can avoid crowd inside the bank.
Much easier to use than the conventional method of banking.
It is much faster application.
All information is available just on single click.
IMPORTANCE
in
MHZ.
2. The minimum capacity of RAM (Random Access Memory) is
512MB
3. Hard disk capacity is 2 GB.
Software Worked Upon:1. Operating system windows 9x or higher.
2. Turbo C as front end.
3. Microsoft Access DBMS as back end.
Windows Environment:-
SYSTEM ANALYSIS
Analysis:-
10
Problem definition
Drawbacks in the existing system
Request for the system change
Requirement analysis
The proposed system
Feasibility study of the proposed system
PROBLEM DESCRIPTION:
11
FUNTIONAL REQUIREMENTS:
User
basic
graphical
tools
such
shapes,objects,brushes,colour tools,eraser etc
as
with
tools
such
as
12
to
allow
usage
and
of
Feasibility Analysis:It determines the best way to achieve the objective of the
system request and is the preliminary steps towards the
design of a system proposed system changes leading
feasibility study fall into one of the three categories.
Change To The Existing System:When the present has some discrepancies, which can be
removed by some alteration, fall under this category.
Completely New System:When the present system whether manual or computerized
has a lot of discrepancies which results in performance
degradation and the system is causing big loss of money and
the time then sometimes it is desirable to replace the older
system with a completely new system .
13
14
SYSTEM DESIGN
Overview:System design is an essential activity in the system
development life cycle. System design is the general
specification of the computer-based solution that was
selected analysis. Design specification forms the basis for
the system development.
The design is a solution the translation of requirement into
ways of meeting them in the process the end user
requirements were translated into specification for a
computer based information system. System design consists
of tow phase:
1. Logical design
2. Physical design
In logical design the detailed specification of the new system
is described i.e. output, the input and the database, all in the
manner that meets project requirement. The activity
following logical design, are the procedures followed in the
physical design of a system takes the logical design blueprint
& produces the program specification, physical file or
database definition with the help of this blue print, e.g.
producing programs, software, and files and working system.
15
Input
design specifies
16
Data items
and transactions validation
detect error.
Method of performing input validation.
to
Output Design:For many Ends-users output is the main reason for developing
the system and the basis on which they will evaluate the
usefulness of the application. Output design involves.
Determines what information to present.
Decide whether to display or print information.
Presentation in an acceptable format.
17
INPUT DESIGN
In this we decide the following input design details:
What data to input
What medium to use
How the data should be arranged or coded
The dialogue to guide customer in providing input
Data items and transactions needing validation to detect errors
Methods for performing cash withdrawing and steps to follow
when errors occur
The design of input also includes specifying the means by which
customer and system operators direct the system in which actions
to take.
Inaccurate input data are the most common use of error in data
processing, errors entered by the data entry operator can be
controlled by the input design is the process of converting user
originated inputs to a computer based format.
The goals of designing input data are to make a data entry as easy
as possible, logical and free from errors. In
entering data
operators need to know the following points: Allocated space for each field
Field sequence, which must match in the source documents
The format in which data fields are entered .The data may be of
different formats but the customer might be required to enter it
only one format.
18
OUTPUT DESIGN
Output design is the most important and the direct source of
information to the customer, efficient, intelligent output design should
improve systems relationship with the customer and in decision making
a form of output is a hard copy from the printer.
Output, refers to the results and information that are
generated by the system. Output is the main reason for developing the
system and the basis on which they will evaluate the usefulness of the
application.
When designing output, we have accomplished the following : Determine what information to present
Decide whether to display, print, or speak the information and
select the output medium
Arrange the presentation of information in an acceptable format
Decide how to distribute the output to intended recipient.
19
20
FUNCTION
1.
this
problem
by
using
Banking
21
2.
3.
4.
5.
6.
22
INTRODUCTION TO C
A C program is built up from a collection of items such as functions
and what we could loosely call global variables. All of these things are
given names at the point where they are defined in the program; the
way that the names are used to access those items from a given place
in the program is governed by rules. The rules are described in the
Standard using the term linkage. For the moment we only need to
concern ourselves with external linkage and no linkage. Items with
external linkage are those that are accessible throughout the program
(library functions are a good example); items with no linkage are also
widely used but their accessibility is much more restricted. Variables
used inside functions are usually local to the function; they have no
linkage. Although this book avoids the use of complicated terms like
those where it can, sometimes there isn't a plainer way of saying
things. Linkage is a term that you are going to become familiar with
later. The only external linkage that we will see for a while will be when
we are using functions.
Functions are C's equivalents of the functions and subroutines in
FORTRAN, functions and procedures in Pascal and ALGOL. Neither
BASIC in most of its simple mutations, nor COBOL has much like C's
functions.
The idea of a function is, of course, to allow you to encapsulate one
idea or operation, give it a name, then to call that operation from
various parts of the rest of your program simply by using the name.
The detail of what is going on is not immediately visible at the point of
use, nor should it be. In well designed, properly structured programs, it
should be possible to change the way that a function does its job (as
long as the job itself doesn't change) with no effect on the rest of the
program.
23
24
MICROSOFT ACCESS
25
26
DATABASE STRUCTURE
27
MODULE DESCRIPTION
MODULE
DESCRIPTION
Create File
Open account
Search
Deposit
Withdraw
Cancel account
28
Report
ER DIAGRAM:
The entity relationship(ER) model is a high level data model .It is
based on the perception of the real world that consists of a collection
of basic objects,called entities and of relationships among these
objects.It was developed to facilate database design by allowing
specification of an enterprise schema,which represent the overall
logical structure of a database.
29
ER DIAGRAM
New Acc
Bank
New
Form
Verify
Rejected
DB
Create Acc
Created
30
Withdraw
Deposit
Withdraw
Bank
Bank
DB
Verify
No
Amount
DB
Deposited
31
User
Modify
Bank
Verify
Account
Modified
Edit the
Form
Details
Incorrect
DB
32
Close
Bank
Account
closed.
DB
33
SNAPSHOTS
34
35
36
37
38
TEST PLAN
Definition of testing:Testing is a vital to the success of the software program
testing includes if all the entries filled by the user are correct
accept by the program requirement then the goal will be
successfully achieved.
System testing requires test plans that consist of several key
activities and step for program, string, system and user
acceptance testing.
The system performance criteria deal with turnaround time,
backup, file protection, the human factor.
A system is tested for online response volume of transactions
stress, recovery from failure and usability then come system
testing which verifies that the whole set of programs hangs
together.
Testing can serve well as testing objectives:1. Testing is process of executing a program with the
intent of finding an error.
2. A good testing case is one that has a high probability of
finding an as get underscored errors.
3. A successful test is one that uncovers an as get
undiscovered error.
Among the rules that can aid in program testing are the
following:-
39
1. Make the test plan section of the program design: Testing should be one of the factors in problem
definition, program design and coding stages.
2. Check all trivial and special cases: - Often the simplest
can lead to the most annoying and mysterious errors.
3. Select test data on random bases doing so will eliminate
any inadvertent bias caused by the programmers select
test data.
4. Plan and document software testing just like hardware
testing: - Testing can never prove that no error exists; so
good software design, like good hardware design, is an
essential section of the testing process.
5. Use the maximum and minimum values of all variables
40
41
2. Interface error.
3. Error in data structures or external data base access.
4. Behavior or performance errors.
5. Initialization and termination errors.
Unit Testing:Unit testing focuses verification efforts of the smallest unit
for software design the software component or module using
the component level design description as a guide, important
control paths ate tested to uncover error with in the boundary
of the module the relative complexity of test and uncovered
for unit testing. The unit test is white box oriented, and the
stop can be conducted in parallel for multiple components.
Unit test procedure :The module interface is tested to insure that information
properly flows into an out of the program unit under test. The
local data structure is examined to insure that data stored
temporarily maintains its integrity during all steps in an
algorithms execution.
Unit testing is normally considered as an adjacent to the
coding step. After source level code has been developed,
reviewed and verified for correspondence to components
level design, unit test case design begins. The review of
design information provides guidance for establishing test
cases that are likely to uncover errors in each of the
42
43
44
Maintenance
This stage is the updating and connecting of the program to
account for changing conditions or field experience. Proper
testing and documentation should significantly reduces the
frequently and extent of the required maintenance. I can now
appreciate why they are so critical:1. Documentation: We provide a technical documentation of a program because
many other programmers will be working with and
maintaining that programmer its life span.
2. Debugging and Testing: A formalized debugging and testing scheme reduce the like
hood of undeleted bugs in the finished program, thus,
reducing the maintenance required on that program.
3. When a change can be localized to a single module, it
makes maintenance much easier .We does not need to worry
about the effects of that change rippling. Throughout other
modules in the system.
4. Structured code: The must common maintenance operation. Operation is
tracking down bugs that went unnoticed during the testing
phase. A program implemented as a series of single entry
single. Exit blocks will facilitate debugging.
5. Portability and generality: Software tends to last longer than hardware. Therefore, a
program written with portability in mind will create less
damage when the inevitable new computers arise. Like wise,
when the user needs change, the truly generate. Program will
require little or no programmer time to adapt to the new
specification.
45
CONCLUSION
SUBMITTED BY:-
Neha Bansal(0701910043)
Evangeline Kharlyngdoh(0701910021)
(B.Tect C.S 3rd yr)
(M.I.T Bulandsahara)
46
47
FILE *fp,*ft;
int recsize;
char choice,any,ch,eno[23];
double dep,withdraw;
double a,n;
struct date d;
/*-----------------------FUNCTION
DEFINATIONS---------------------*/
void acc_info(cust *p);
void add();// to add new account
void list();
void transac();//to make
transactions(deposit/withdrawal)
void del(); // to delete a perticular account
void report(); // to print report on customer
balance
float calculate_interest(cust *p); //To
calculate intrest
int no_of_days(int d1, int m1, int y1, int d2,
int m2, int y2);
void calbig();
void intro();
void calwin();
// these 4
functions
void load();
void calbox();
// for creating
appearence
48
c = 45;
box(12,3,69,5);
textcolor(CYAN + BLINK);
gotoxy(31,4); cprintf("W O R L D B A N K");
box(16,8,65,22); textcolor(CYAN + BLINK);
gotoxy(30,9);cprintf(" W E L C O M E ");
box(16,11,65,13); textcolor(CYAN);
gotoxy(38,12); cprintf("LOGIN");
textcolor(9);
gotoxy(28,16); cprintf("ENTER PASSWORD :
");
textcolor(RED);
_setcursortype(_SOLIDCURSOR); // To Show
Solid cursor.
while(i <= 9 || ps !='\r')
{
ps = getche();
gotoxy(c,16);
cprintf("*");
if (ps == '\r')
break;
else
{
p[i] = ps;
c++;
i++;
}
if (i > 12) break;
}
50
p[i] = '\0';
_setcursortype(_NOCURSOR); // To disable
the cursor.
if(strcmp(p,pass) == 0)
{
gotoxy(28,18);
textcolor(YELLOW + BLINK);
cprintf("YOU ARE SUCCESSFULY
LOGIN...
");
delay(1000);
}
else
{
gotoxy(27,18);
cprintf("SORRY! ACCESS DENIED.....
");
gotoxy(27,20);
cprintf("LET'S TRY AGAIN [Y]/[N] : ");
choice = getche();
if (choice == 'Y'|| choice == 'y'||choice ==
'\r')
goto password;
else
exit(0);
}
} //end of pass word block
51
fp = fopen("bank.txt","rb+");
if (fp == NULL)
{
fp = fopen("bank.txt","wb+");
if (fp==NULL)
{
puts("cannot create a file ");
exit(1);
}
}
while(1)
{
_setcursortype(_SOLIDCURSOR);
calwin(); textbackground(BLACK);
clrscr(); //yellow
calwin(); textbackground(LIGHTGRAY);
clrscr();
window(19,7,64,39);
delay(300); textbackground(BLACK);
textcolor(BROWN); clrscr();
window(18,6,62,37);//blue window
textbackground(LIGHTBLUE);
textcolor(GREEN); clrscr(); delay(100);
gotoxy(12,2);
cprintf("================== \n");
highvideo(); textcolor(WHITE+BLINK);
gotoxy(11,3); cprintf(" W O R L D B A N
K\n");
52
textcolor(GREEN);
gotoxy(12,4);
cprintf("==================\n");
gotoxy(4,6); cprintf("M A I N - M E N U
\n");
gotoxy(4,7);
cprintf("#################");
getdate(&d);
d1 = d.da_day ;
m1 = d.da_mon ;
y1 = d.da_year ;
gotoxy(34,6); cprintf("%d-%d%d",d1,m1,y1);
gotoxy(4,9); cprintf("A-> Adding a new
Account\n");
gotoxy(4,12); cprintf("L-> List all
Accounts\n");
gotoxy(4,15); cprintf("T-> Transaction
[Deposit/Withdraw]\n");
gotoxy(4,18); cprintf("D-> close any
account \n");
gotoxy(4,21); cprintf("F-> Find an
Account\n");
gotoxy(4,24); cprintf("R-> Reports \n");
gotoxy(4,27); cprintf("E-> Exit \n ");
gotoxy(4,29); cprintf("Enter your choice
[A,L,T,D,F,R,E] :");
fflush(stdin); ch = getchar();
53
switch(toupper(ch))
{
case 'A' :
calwin();
textbackground(BLUE); textcolor(BLACK);
clrscr();
add();
break;
/*--------------------------------------------------------------*/
case 'L':
calwin();delay(100);
textbackground(LIGHTCYAN);
textcolor(BLACK); clrscr();
list();
break;
/*-------------------------------------------------------------*/
case 'T':
calwin();
textbackground(WHITE); textcolor(BLACK);
clrscr();
transac();
break;
/*----------------------------------------------------------*/
case 'D' :
calwin();
del();
break;
54
/*-------------------------------------------------------------*/
case 'F':
_setcursortype(_NOCURSOR);
k=valid();
if(k==2)
{
rewind(fp);
while(fread(&p1,sizeof(p1),1,fp)==1)
{
if(strcmp(p1.cus_ac_no,eno)==0)
{
acc_info(&p1);
}
}
}
else
{
calbox(); highvideo();
textcolor(WHITE+BLINK);
gotoxy(15,12); cprintf(" THIS IS INVALD
NUMBER.");
gotoxy(18,14); cprintf(" TRY AGAIN");
getch();
}
break;
55
/*-------------------------------------------------------------*/
case 'R':
calbig();
gotoxy(4,12);
cprintf("=======================
======================");
gotoxy(14,14);cprintf("REPORT OF WORLD
BANK CUSTOMERS");
gotoxy(4,16);
cprintf("=======================
======================");
gotoxy(4,21); cprintf(" Display customers
account to view details :");
gotoxy(5,23);cprintf("digit :");
gotoxy(13,23);scanf("%lf",&n);
report(n);
break;
/*-----------------------------------------------------------*/
case 'E':
intro();
highvideo(); textcolor(LIGHTGRAY+BLINK);
gotoxy(24,5); cprintf("THANK YOU FOR
USING THIS SOFTWARE");
highvideo(); textcolor(GREEN);
getch();
fclose(fp);
56
exit(1);
break;
/*-------------------------------------------------------------*/
default :
_setcursortype(_NOCURSOR);
window(23,43,57,49);
textbackground(BLACK); clrscr();
window(22,42,56,48);
textbackground(BLUE);
clrscr();highvideo(); textcolor(WHITE+BLINK);
gotoxy(5,3); cprintf(" SORRY WRONG
CHOICE....");
gotoxy(5,5); cprintf(" PRESS ANY KEY TO
CONTINUE....");
getch();
calwin(); clrscr();
break;
}//end of switch
}//end of while
} //end of void main
/
*----------------------------------------------------------------*/
void calwin() // Painting of whole screen
{
57
window(1,1,80,50); clrscr();
}
/
*----------------------------------------------------------------*/
int valid( )// Validation of Account number
{
int k=1;
calbox();
gotoxy(6,8); cprintf(" Enter customer
account number : ");
gotoxy(6,10); cprintf("
***************************** ");
gotoxy(62,7); fflush(stdin); gets(eno);
rewind(fp);
while(fread(&p1,sizeof(p1),1,fp)==1)
{
if(strcmp(p1.cus_ac_no,eno)==0)
{
k=2;
break;
}
}
return(k);
}
58
/*----------------------------------------------------------------------*/
void acc_info(cust *p)//Printing of an Account
Details
{
calbox();
_setcursortype(_NOCURSOR);
gotoxy(8,2);
cprintf("=======================
=====================\n");
gotoxy(8,3); cprintf("......Customer's
Information .......");
gotoxy(8,4);
cprintf("=======================
=====================\n");
gotoxy(7,7); cprintf("|-> Customer Account
number is:- %s",p->cus_ac_no);
gotoxy(7,10); cprintf("|-> Customer Name
is:-%s",p->cus_name);
gotoxy(7,13); cprintf("|-> Customer Address
is:- %s",p->cus_add);
gotoxy(7,16); cprintf("|->Customer Phone
number is:- %s",p->cus_ph_no);
p->cus_bal+=calculate_interest(p);
gotoxy(7,19); cprintf("|-> Customer Balence
is :- %.3lf Rs",p->cus_bal);
59
strcpy(p1.cus_ac_no,eno);
gotoxy(5,5); cprintf(" Enter customer
name : ");
fflush(stdin); gets(p1.cus_name);
gotoxy(5,9); cprintf(" Enter customer
address : ");
fflush(stdin); gets(p1.cus_add);
gotoxy(5,14); cprintf(" Enter customer
phone number :");
fflush(stdin); gets(p1.cus_ph_no);
gotoxy(5,18); cprintf(" Enter the
amount you want deposit :");
scanf("%lf",&p1.cus_bal);
gotoxy(5,19); cprintf("
============================
===== :");
getdate(&d);
p1.dd = d.da_day ;
p1.mm = d.da_mon ;
p1.yy = d.da_year ;
fseek(fp,0,SEEK_END);
fwrite(&p1,sizeof(p1),1,fp);
gotoxy(5,22); cprintf("Add another account
(y/n) : ");
fflush(stdin); any = getchar();
}while(tolower(any)=='y');//end of do
while
// getch();
}
61
/*----------------------------------------------------------*/
void list()//Printing all Accounts Details
{
clrscr();
rewind(fp);
while(fread(&p1,sizeof(p1),1,fp)==1)
{
acc_info(&p1);
}
}
/*-----------------------------------------------------------*/
void transac()//Updating an Account
{
int k,p,t,r;
clrscr();
k=valid();
rewind(fp);
if(k!=2)
{
_setcursortype(_NOCURSOR);
calbox(); highvideo();
textcolor(WHITE+BLINK);
gotoxy(12,12); cprintf(" This is not a
valid number ");
gotoxy(19,14); cprintf(" Try again");
getch();
}
else
{
62
while(fread(&p1,sizeof(p1),1,fp)==1)
{
if(strcmp(p1.cus_ac_no,eno)==0)
{
calbox();
gotoxy(11,4); cprintf(" What do you want
to do : ");
gotoxy(5,7); cprintf("1->.Deposit");
gotoxy(5,10); cprintf("2->.Withdraw");
gotoxy(5,13); cprintf("3->Exit");
gotoxy(5,17); cprintf("Enter your
choice :");
fflush(stdin);
choice=getchar();
switch(choice)
{
/*----------------------------------------------------*/
case '1':
calbox();
gotoxy(5,5); cprintf("Enter the money
you want to Deposit :");
gotoxy(8,7);cprintf("Rs :");
scanf("%lf",&dep);
p1.cus_bal+=dep;
acc_info(&p1);
recsize = sizeof(p1);
fseek(fp,-recsize,SEEK_CUR);
fwrite(&p1,sizeof(p1),1,fp);
63
getch();
break;
/*---------------------------------------------------*/
case '2':
calbox();
gotoxy(10,12); cprintf("Enter the
money you want to Withdraw : ");
gotoxy(12,14);cprintf("Rs :");
gotoxy(17,14);scanf("%lf",&withdraw);
if(p1.cus_bal<withdraw)
{
_setcursortype(_NOCURSOR);
calbox(); highvideo();
textcolor(WHITE+BLINK);
gotoxy(7,12);cprintf("YOU DONT'VE THIS
MUCH MONEY IN YOUR ACCOUNT");
gotoxy(19,14); cprintf("TRY AGAIN");
getch();
}
else
{
p1.cus_bal-=withdraw;
recsize = sizeof(p1);
fseek(fp,-recsize,SEEK_CUR);
fwrite(&p1,sizeof(p1),1,fp);
acc_info(&p1);
}
break;
64
/*--------------------------------------------------------*/
case '3':
break;
/*--------------------------------------------------------*/
default:
_setcursortype(_NOCURSOR);
window(23,43,57,49);
textbackground(BLACK); clrscr();
window(22,42,56,48);
textbackground(BLUE);
clrscr();highvideo(); textcolor(WHITE+BLINK);
gotoxy(5,3); cprintf(" SORRY WRONG
CHOICE....");
gotoxy(5,5); cprintf(" PRESS ANY KEY TO
CONTINUE....");
getch();
calwin(); clrscr();
break;
/*--------------------------------------------------------------*/
} //end of switch
}// end of inner if
}//end of while
}//end of outer else
}//end of Transaction function
/*----------------------------------------------------------*/
void del() //Deletion of an Account
65
{
int k;
clrscr(); calbox();
k=valid();
_setcursortype(_NOCURSOR);
if(k==2)
{
calbox(); highvideo();
textcolor(WHITE+BLINK);
gotoxy(16,12); cprintf(" ARE YOU SURE
");
gotoxy(7,14); cprintf(" YOU WANT TO
CLOSE THIS ACCOUNT (Y/N):\n");
if(toupper(getchar())=='Y')
{
ft = fopen("temp.dat","wb+");
rewind(fp);
while(fread(&p1,sizeof(p1),1,fp) == 1)
{
if(strcmp(p1.cus_ac_no,eno)!=0)
{
fwrite(&p1,sizeof(p1),1,ft);
}
}
fclose(fp); fclose(ft);
remove("bank.txt");
rename("temp.dat","bank.txt");
fp = fopen("bank.txt","rb+");
66
} //end of inner if
} //end of outer if
else
{
calbox(); highvideo();
textcolor(WHITE+BLINK);
gotoxy(12,12); cprintf(" THIS IS NOT A
VALID NUMBER ");
gotoxy(19,14); cprintf(" TRY AGAIN");
getch();
}
}
/*--------------------------------------------------------------------*/
void report(double k)
{
int count=1,i=0,temp;
calbig();
rewind(fp);
_setcursortype(_NOCURSOR);
factor_10: {
if(count%10==0)
{
temp=count;
rewind(fp); count=1;
67
while(fread(&p1,sizeof(p1),1,fp) == 1)
{
count++;
if(count<temp) continue;
else
break;
}
}
while(fread(&p1,sizeof(p1),1,fp)==1)
{
if(p1.cus_bal>=k)
{
gotoxy(4,13);
cprintf("=======================
======================");
gotoxy(6,15); cprintf("Account no");
gotoxy(23,15); cprintf("Name");
gotoxy(40,15); cprintf("Balence");
gotoxy(4,17);
cprintf("=======================
======================");
gotoxy(6,19+i); cprintf(" %s
",p1.cus_ac_no);
gotoxy(23,19+i); cprintf(" %s
",p1.cus_name);
p1.cus_bal+= calculate_interest(&p1);
gotoxy(40,19+i); cprintf("
%.3lf",p1.cus_bal);
count++;
i=i+2;
68
if(count%10==0)
{
_setcursortype(_NOCURSOR);
i=0;
gotoxy(4,37);
cprintf("-----------------------------------------------------"
);
highvideo(); textcolor(WHITE+BLINK);
gotoxy(7,38); cprintf(" <->Press any
key to continue ");
getch(); calbig();
goto factor_10;
}
}// end of inner if
} //end of while
} //end of factor_10 block
gotoxy(4,11);cprintf("The details of
customers account are :",k,count-1);
getch();
}
/*--------------------------------------------------------------------*/
void calbox() //creat small window
{
calwin();
textbackground(LIGHTGRAY);clrscr();
69
//black window
window(9,9,62,35); textbackground(BLACK);
textcolor(BROWN); clrscr();
//blue window
window(8,8,60,33);delay(150);
textbackground(LIGHTBLUE);
textcolor(GREEN); clrscr();
box(2,2,52,25);
}
/*---------------------------------------------------------------------*/
void calbig() //creat huge window
{
int count=0;
window(1,1,80,50);
textbackground(LIGHTCYAN);clrscr();
window(5,5,73,45);
textbackground(BLACK);clrscr();
window(3,3,70,42);
textbackground(BLUE);textcolor(GREEN);
clrscr();
box(3,2,66,37);
rewind(fp);
while(fread(&p1,sizeof(p1),1,fp)==1)
count++;
gotoxy(15,3); cprintf(" REPORT OF WORLD
BANK CUSTOMERS");
70
gotoxy(14,4);
cprintf("#######################
###########");
gotoxy(5,7); cprintf("Total No Of Acconts
Are :- %d",count);
gotoxy(5,8);
cprintf("---------------------------------");
}
/*--------------------------------------------------------*/
void intro()
{
_setcursortype(_NOCURSOR);
calwin();
textbackground(BLACK);
clrscr();
box(15,8,69,30); //calbox();
highvideo(); textcolor(CYAN);
gotoxy(25,11); cprintf("\xde PROJECT ON
BANKING AUTOMATION \xde");
textcolor(GREEN);
box(15,8,69,13);
highvideo(); textcolor(CYAN);
gotoxy(20,16);cprintf("Created By : ");
gotoxy(20,18);cprintf(" NEHA and EVA ");
gotoxy(20,19);cprintf(" B.tech CSE");
gotoxy(20,20);cprintf(" M.I.T. Bulandshahr
");
71
/*
gotoxy(30,19);cprintf(" ");
gotoxy(30,21);cprintf("\xde B.tech CSE
\xde");
gotoxy(30,23);cprintf("\xde M.I.T
\xde");
gotoxy(30,25);cprintf("\xde Bulandshahr
\xde");
gotoxy(30,27);cprintf("\xde Email:eve.essence@gmail.com\xde");
textcolor(WHITE+BLINK);
gotoxy(30,19); cprintf("\xde Neeraj Sachdeva
\xde");
gotoxy(30,32);cprintf("<-> Press any key to
continue"); */
}
/*-----------------------------------------------------------*/
void box(int a, int b, int c, int d) //to
generarate box like finishing
{
int i,j ;
for( i = a; i < c; i++)
{
gotoxy(i,b); printf("\xcd");
gotoxy(i,d); printf("\xcd");
}
for( j = b; j < d; j++)
{
gotoxy(a,j); printf("\xba");
72
gotoxy(c,j); printf("\xba");
}
gotoxy(a,b);
gotoxy(c,b);
gotoxy(a,d);
gotoxy(c,d);
printf("\xc9");
printf("\xbb");
printf("\xc8");
printf("\xbc");
}
/
*---------------------------------------------------------------------*/
void load() // For creating loading effect
{
int a=5,b=19,c=78,d=21,i,j,k;
calwin();
textbackground(BLACK);
clrscr();
gotoxy(38,17);
cprintf("Loading....");
box(a,b,c,d);
_setcursortype(_NOCURSOR);
textcolor(BLUE);
for(i=1;i<(c-5);i++)
{
gotoxy(a+i,b+1);
delay(60);
cprintf("\xdd");
}
for(i=1;i<(c-5);i++)
{
73
gotoxy(a+i,b+1);
delay(60);
cprintf("\xdb");
}
_setcursortype(_NOCURSOR);
textcolor(GREEN);
}
/
*-------------------------------------------------------------------*/
int no_of_days(int d1, int m1, int y1, int d2, int
m2, int y2)
{
static int months[] =
{31,28,31,30,31,30,31,31,30,31,30,31} ;
int days = 0 ;
while (d1 != d2 || m1 != m2 || y1 != y2)
{
days++ ;
d1++ ;
if (d1 > months[m1-1])
{
d1 = 1 ;
m1++ ;
}
if (m1 > 12)
{
m1 = 1 ;
y1++ ;
74
}
}
return days ;
}
/*-------------THIS FUNCTION CALCULATES
INTEREST------------------*/
float calculate_interest(cust *p)
{
int d1, m1, y1, d2, m2, y2, months=0, days
;
d1 = p->dd ;
m1 = p->mm ;
y1 = p->yy ;
getdate(&d);
d2 = d.da_day ;
m2 = d.da_mon ;
y2 = d.da_year ;
p->cus_intrst=0.0 ;
if ((y2<y1) || (y2==y1 && m2<m1) ||
(y2==y1 && m2==m1&& d2<d1))
return p->cus_intrst;
days = no_of_days(d1,m1,y1,d2,m2,y2) ;
if (days >= 30)
{
months = days/30 ;
p->cus_intrst = ((p->cus_bal*2)/100) *
months ;
}
75
return p->cus_intrst ;
}
/*---------------------------THE END
-----------------------------------*/
BIBLIOGRAPHY
76
1. Let us C:
Yashavant P.Kanetkar
77