Professional Documents
Culture Documents
Sad Project ON Library Management
Sad Project ON Library Management
ON
LIBRARY MANAGEMENT
This is to certify that the SAD Project entitled “Library Management System” submitted by
Chandan Verma,Lokeshwar Singh,Apoorva Misra,Pramod Kumar having Roll Number
11853,11855,11851,50204 for the partial fulfillment of the requirements of Bachlor of
Technology In Computer Science Engg. degree of Bells Institute of Management &
Technology,Shimla.
This is to certify that the SAD Project entitled Library Management System submitted by
Chandan Verma,Lokeshwar Singh,Apoorva Misra,Pramod Kumar having Roll Number
11853,11855,11851, 50204 for the partial fulfillment of the requirements of Bachlor of
Technology In Computer Science Engg. degree of Bells Institute of Management &
Technology,Shimla, embodies the bonafide work done by him/her under my/our supervision.
DECLARATION
Chandan Verma
Lokeshwar Singh
Apoorva Misra
Pramood Kumar
First of all We would like to thank our project guide Miss Disha Guleria for sparing her
precious time, cooperating making suggestion and creative and guiding us through
out.Working under her was a good learning experience which will always be remembered. I
also grateful to her sparing valuable time and providing with the required material and
information for study. I also express our deep sense of gratitude to other lecturers of Computer
Science Engg. Deptt. For bearing and cooperating with us and helping us through out the
project.
Project Mambers
Chandan Verma
Lokeshwar Singh
Apoorva Misra
Pramood Kumar
Chapter 1 Introduction 1
1.1 Process Description 1
1.2 Hardware and Software requirements 4
1.3 Phases in Development of Department Software 5
1.4 Software Life Cycle Model 6
Chapter 2 Planning 7
2.1 Problem Description 7
2.2 System Study 8
2.3 Feasibility Study 9
Chapter 3 Analysis 11
3.1 Analysis 11
3.2 Components of SRS 12
Chapter 4 Design 13
4.1 Design 13
4.2 Level 0 DFD Diagram 14
4.3 Level 1 DFD Diagram 15
4.4 Level 2 DFD Diagram 17
4.5 E-R Digram 19
Chapter 5 Implementation 20
5.1 Implementation 20
5.2 Testing 20
5.3 Levels of Testing 21
Chapter 6 Coding 25
The project titled “Library Management System” is Library management software for
monitoring and controlling the transactions in a library.The project “Library Management System”
is developed in c++ language, which mainly focuses on basic operations in a library like adding
new member, new books, and updating new information, searching books and members and
facility to borrow and return books.
This project of “Library Management System” of gives us the complete information about the
library. We can enter the record of new books and retrieve the details of books available in the
library. We can issue the books to the students and maintain their records and can also check how
many books are issued and stock available in the library. In this project we can maintain the late
fine of students who returns the issued books after the due date.
1.1PROCESS DESCRIPTION
The Library Management System is designed & developed for a receipt and issuance of books in
the library along with the student’s details. The books received in the library are entered in Books
Entry form and the new student is entered in the student entry form. When the student wants to get
the desired book the same is issued on the availability basis to the student. The issuance and due
date for the returning of the book is also entered into the Book Issue form under third menu Book
Issue. The student has to pay the fine if any on the basis of no. of days delayed deposit of the book
in the library.
INTRODUCTION TO C++
An object oriented language combines the data to its function or code in such a way that access to
data is allowed only through its function or code. Such combination of data and code is called an
object.
The C++ programming language was introduced by Bjarne Stroustrup of the AT&T laboratories in
1985 as an extension of C, with additional features borrowed from the esoteric language Simula.
Since then, C++ has grown rapidly in response to the practical need for a programming language
that is able to efficiently handle composite and diverse data types. The language implementation is
pivoted on the ingenious concept of object oriented programming (OOP). Today, C++ dominates
the commercial market and is favored among system programmers and application developers.
C++ is a generalization of C, but accomplishes much more than C, to the extent that it should be
regarded, studied, and taught as a separate language. It is neither necessary nor recommended to
study C as a prerequisite of C++, though knowledge of C can be helpful.
FEATURE OF C++
Before starting to learn C++ it is essential to have a basic knowledge of the concepts of Object
oriented programming. Some of the important object oriented features are namely:
• Objects
• Classes
• Inheritance
• Data Abstraction
• Data Encapsulation
• Polymorphism
• Overloading
• Reusability
In order to understand the basic concepts in C++, a programmer must have a good knowledge of
the basic terminology in object-oriented programming. Below is a brief outline of the concepts of
object-oriented programming languages :
Objects:
Object is the basic unit of object-oriented programming. Objects are identified by its unique name.
An object represents a particular instance of a class. There can be more than one instance of a
class. Each instance of a class can hold its own relevant data.
An Object is a collection of data members and associated member functions also known as
methods.
Classes:
Classes are data types based on which objects are created. Objects with similar properties and
methods are grouped together to form a Class. Thus a Class represents a set of individual objects.
For example consider we have a Class of Cars under which Santro Xing, Alto and WaganR
represents individual Objects. In this context each Car Object will have its own, Model, Year of
Manufacture, Color, Top Speed, Engine Power etc., which form Properties of the Car class and the
associated actions i.e., object functions like Start, Move, and Stop form the Methods of Car Class.
No memory is allocated when a class is created. Memory is allocated only when an object is
created, i.e., when an instance of a class is created.
Inheritance:
Inheritance is the process of forming a new class from an existing class or base class. The base
class is also known as parent class or super class. The new class that is formed is called derived
class. Derived class is also known as a child class or sub class. Inheritance helps in reducing the
overall code size of the program, which is an important concept in object-oriented programming.
Data Abstraction:
Data Abstraction increases the power of programming language by creating user defined data
types. Data Abstraction also represents the needed information in the program without presenting
the details.
Data Encapsulation:
Data Encapsulation combines data and functions into a single unit called Class. When using Data
Encapsulation, data is not accessed directly; it is only accessible through the functions present
inside the class. Data Encapsulation enables the important concept of data hiding possible.
Polymorphism:
Polymorphism allows routines to use variables of different types at different times. An operator or
function can be given different meanings or functions. Polymorphism refers to a single function or
multi-functioning operator performing in different ways.
Overloading:
Reusability:
This term refers to the ability for multiple programmers to use the same written and debugged
existing class of data. This is a time saving device and adds code efficiency to the language.
HARDWARE REQUIREMENTS
SOFTWARE REQUIREMENTS
Procedures
Methods
Tools
They provide the guidelines as how to apply these methods and tools, how to produce the
deliverables at each stage, what controls to apply, and what milestones to uses to assess the
progress. There exist a number of software
Development paradigms, each particular paradigm depends on the nature of the application, the
programming language used, and the controls and the deliverables required. The development
of such successful system depends not only on the use of applicable methods and techniques
but also the developer’s commitment to the objective of the system.
A successful system must: -
1. Satisfy the user requirements.
2. Be easy to understand by user and operator.
3. Be easy to operate.
4. Have a good user interface.
Problem
definition
Analysis
Design
Coding
Testing
Maintenance
2
Library Management System (CSE 4th sem)
PLANNING
PLANNING
2.1PROBLEM DESCRIPTION
Initially the work began with the study of the existing system.
Existing System:
The department of any institution looks up after the entire financial network
Which is the essence in running of an enterprise. The department looks up after the various heads
under which expenses have to be incurred and also the various heads under which the payments
have to be collected. The efficient management of finances ensures profits and hence leads to
prosperity. Thus an efficient department of any institution is the backbone
Of success. This system (before computerization) comprised of manual handling of a range of
components of the department. The reports traveled
From staff down in the hierarchy to the upper levels. This involved redundantly copying the data
for personal record maintenance and then the higher authorities maintain the data in the cashbook.
At the end of the day the record are finalized in the cashbook.
2.2SYSTEM STUDY
EXISTING SYSTEM
PROPOSED SYSTEM
Since these days IT sector is growing rapidly and computers are now used in almost every field
hence we have developed software with which Air Ticket Reservation can be made easily and it is
convenient to maintain the records of the passengers.
This software includes not only making reservation but also cancellation of ticket, making
enquiry about fair, flights etc and also shows the list of passengers for a particular flight.
We can easily access all the information of a passenger and may alter the records as
needed.
Maintaining records and providing information about a particular flight becomes very easy
and there is no chance of making mistakes.
This project is mainly designed to help the users in the airlines department to do their work in a
more organized and in a more efficient way. Earlier there was a fear of data loss and data
corruption so this system was developed in keeping view of providing security and more user-
friendly system to the users. Also this system has made the easy availability of the data to the user.
Being a user friendly system the user can get data at any time at the request.
2.3FEASIBILITY STUDY
A feasibility study is a test of a system proposal according to its work-ability, impact on the
organization, ability to meet user needs and effective use of resources. For all new systems, the
Economic Feasibility
This is related to whether the organization can afford the system software and hardware
configuration. The system should not increase the overhead cost rather it should cut down
overhead cost. It also sees whether current manpower is sufficient to run the system and not much
training is required to be given to the employees to run the system. Thus with all these factors we
can conclude that economically the proposed system is feasible.
Operational Feasibility
The organization is facing lot of problems like time consumption, error prone records etc in the
current manual system. The users are willing to work in new environment because ticket
reservation and other processes are done in very short span of time and effectively. Enquiry about
flights and passenger lists can be seen easily and fast, which will enable the employees to work
efficiently and fast. Thus we can conclude that the management and staff are ready to computerize
the system.
Technical Feasibility
For the purpose of development of proposed system the available hardware i.e. Pentium 1
microprocessor, 32 MB RAM, and 1 GB hard disk is sufficient. Where as the software required is
Behavioral Feasibility
When a survey was conducted and the staff of the airlines was asked if it was ready to work with
the proposed system, we found a mixed reaction. While some of the employees were more than
willing to work with the new system, there were some who objected to it as they feared that their
job may get into jeopardy. But when it was made clear to them that there jobs are fully secured and
this system will not effect their jobs rather it will ease there work they agreed to work with this
system. Thus this system is behavioral feasible. Thus the proposed system is feasible from all the
aspects that are discussed above and it will work well when installed. It is easy to use and hence it
won’t be necessary to provide any special training to staff members to execute the proposed
system.
3
ANALYSIS
Library Management System (CSE 4th sem)
3.1ANALYSIS
Analysis also known as requirement analysis and specification the main aim of this phase is to
completely understand the requirements of the customer and then to document them properly. This
also covers the detailed study of requirements of both the user and the software.
This activity is basically concerned with that of the system such as:
*What are the inputs to the system?
*What are the processes required.
*What are the outputs expected?
*What are the constraints of the system?
Gathering of entire information about the working of the work assigned. If the product involves
developing new software for which no working model exists then the information is
collected through questionnaire, which is filled by the customer, here the customer can
be Conversed with too.
Requirement Specification (SRS) document that is presented to the customer and this document is
used as a written agreement between the
Developer and the customer, such that any confusion that arises later can be solved viewing the
norms in the document. Once the customer is
Satisfied with the documented specifications, the SRS can be used for further phases involved in
development of the software.
3.2COMPONENTS OF SRS
Before starting to design a software project, it is extremely important to define the precise
requirements of the customer. However, once the precise
User requirements are identified, analyzed and inconsistencies are weeded out, a document is
written called Software Requirement Specification (SRS).
It should discuss the functionalities required from the system. The functional
requirements of the system as documented in the srs should clearly describe each
function which the system would support along with the corresponding input and output
dataset.
2) Nonfunctional requirements
It deals with the characteristics of the system that cannot be expressed as functions. The
nonfunctional requirements may also include the reliability issue, accuracy of results
human computer interface issue, and constraint on system implementation. The
constraints on system implementation describes aspects such as specific data base
management system to be used as per the customer request
3) Goal of implementation
It gives some general suggestion regarding development. These suggestions guide trade
off among design decisions. It might document issues such as revisions to the system
functionality that may be required in future, new device to be supported in the future,
reusability issue, etc.
4
DESIGN
4.1DESIGN
In Level 0 DFD diagram, it will display the menus of the project that iswhat are all we can do in
the project. From that we can select the option what we aregoing to do. Based upon the condition it
display the next screen for the selected operation.
In Level 1 DFD diagram it takes the input details and store the details inthe database. It takes the
details separately for each table and store details separately ineach table.
5
Library Management System (CSE 4th sem)
IMLEMENTATION
5.1IMLEMENTATION
This chapter deals with implementation of the prototype. Rest of the chapter is organized as
follows. Section presents Testing of the developed system, Section gives the various DFD’s of the
developed system and Section presents the flowchart. Finally Summary of the chapter is given in
section .
5.2TESTING
The aim of the testing process is to identify all the defects existing in a software product. However
for most practical systems even carrying out the testing phase is not possible to guarantee that the
software is error free. This is because of the fact that the input data domain of most of the software
products is large. It is not practical to test the software exhaustively with respect to each of the
value that the input data may assume. We should not underestimate the importance of testing.
Testing is a program consisting of set of test inputs (or test cases) and
observing if the program behaves as expected, then the conditions under which a failure occurs are
noted for debugging and correction.
Acceptanc
Client
e
needs
System testing
Requirements
Integration
Design testing
UNIT TESTING
Each individual form (Module) of the program was tested to ensure that each performs the function
for it was designed. This testing involves the testing of the interface to ensure that the information
flows into and out of the program unit under test. All the independent paths through the control
structures in each module are tested. The testing involves the data validation for each form and the
complete functionality of the form itself. The test cases can be designed in any of the two ways:
• Black-Box Testing
• White-Box Testing
In Mutation testing software is first tested by using an initial testing method. After the initial
testing is complete, mutation testing is taken up. The basic idea is to make a few arbitrary small
changes to the program at the time such as changing a conditional operator or changing the type of
variable. Each time the program is changed, it is a mutant program and the change effected is
called a mutant. A mutant program is tested against the full test suit of the program. If there exists
INTEGRATION TESTING
The integration testing was performed on the unit test modules. These modules were combined
into subsystems, which were then tested. The goal was to check whether the integration of the
modules was poor and to detect design errors by focusing on testing the interconnection between
modules. The flow of information from one stage to other was verified and expected results were
checked. The integration plan specifies the steps and the order in which modules are combined to
realize full system. After each integration, partially integrated system was checked. The primary
objective of integration testing is to test the module interfaces. The integration plan can be
developed based on any of the following approaches:
• Big-bang approach
• Top-down approach
• Bottom-up approach
• Mixed approach
SYSTEM TESTING
The entire software system was tested. The goal was to see if the software met its requirements.
Here the validation exercises were carried out to detect application level errors. The functionality
The users of the system with the inputs of realistic data performed this testing. The only emphasis
in this testing was on the functionality testing, as the users are not aware of the technical aspects of
the system. The testing here was focused on the external behavior of the system , the internal logic
of the system was not emphasized. This testing was also done in controlled environment with
logging of all errors. Based on the errors found in the system, the users accepted the system with
few modifications to the system, in order to rectify the errors.
All these testing are implemented in the various steps at the development of the project.
APPROACHES TO TESTING
6
CODING
#include<fstream.h>
#include<conio.h>
#include<stdio.h>
#include<process.h>
#include<string.h>
#include<iomanip.h>
//***************************************************************
// CLASS USED IN PROJECT
//****************************************************************
class book
{
char bno[6];
char bname[50];
char aname[20];
public:
void create_book()
{
cout<<"\nNEW BOOK ENTRY...\n";
cout<<"\nEnter The book no.";
cin>>bno;
cout<<"\n\nEnter The Name of The Book ";
gets(bname);
cout<<"\n\nEnter The Author's Name ";
gets(aname);
cout<<"\n\n\nBook Created..";
}
void show_book()
{
void modify_book()
{
cout<<"\nBook no. : "<<bno;
cout<<"\nModify Book Name : ";
gets(bname);
cout<<"\nModify Author's Name of Book : ";
gets(aname);
}
char* retbno()
{
return bno;
}
void report()
{cout<<bno<<setw(30)<<bname<<setw(30)<<aname<<endl;}
class student
{
char admno[6];
char name[20];
char stbno[6];
int token;
public:
void create_student()
{
clrscr();
Library Management System (CSE 4th sem)
cout<<"\nNEW STUDENT ENTRY...\n";
cout<<"\nEnter The admission no. ";
cin>>admno;
cout<<"\n\nEnter The Name of The Student ";
gets(name);
token=0;
stbno[0]='/0';
cout<<"\n\nStudent Record Created..";
}
void show_student()
{
cout<<"\nAdmission no. : "<<admno;
cout<<"\nStudent Name : ";
puts(name);
cout<<"\nNo of Book issued : "<<token;
if(token==1)
cout<<"\nBook No "<<stbno;
}
void modify_student()
{
cout<<"\nAdmission no. : "<<admno;
cout<<"\nModify Student Name : ";
gets(name);
}
char* retadmno()
{
return admno;
}
char* retstbno()
{
return stbno;
}
int rettoken()
{
return token;
Library Management System (CSE 4th sem)
}
void addtoken()
{token=1;}
void resettoken()
{token=0;}
void report()
{cout<<"\t"<<admno<<setw(20)<<name<<setw(10)<<token<<endl;}
//***************************************************************
// global declaration for stream object, object
//****************************************************************
fstream fp,fp1;
book bk;
student st;
//***************************************************************
// function to write in file
//****************************************************************
void write_book()
{
char ch;
fp.open("book.dat",ios::out|ios::app);
do
{
Library Management System (CSE 4th sem)
clrscr();
bk.create_book();
fp.write((char*)&bk,sizeof(book));
cout<<"\n\nDo you want to add more record..(y/n?)";
cin>>ch;
}while(ch=='y'||ch=='Y');
fp.close();
}
void write_student()
{
char ch;
fp.open("student.dat",ios::out|ios::app);
do
{
st.create_student();
fp.write((char*)&st,sizeof(student));
cout<<"\n\ndo you want to add more record..(y/n?)";
cin>>ch;
}while(ch=='y'||ch=='Y');
fp.close();
}
//***************************************************************
// function to read specific record from file
//****************************************************************
fp.close();
if(flag==0)
cout<<"\n\nBook does not exist";
getch();
}
fp.close();
if(flag==0)
cout<<"\n\nStudent does not exist";
getch();
}
//***************************************************************
// function to modify record of file
//****************************************************************
void modify_book()
{
char n[6];
int found=0;
clrscr();
Library Management System (CSE 4th sem)
cout<<"\n\n\tMODIFY BOOK REOCORD.... ";
cout<<"\n\n\tEnter The book no. of The book";
cin>>n;
fp.open("book.dat",ios::in|ios::out);
while(fp.read((char*)&bk,sizeof(book)) && found==0)
{
if(strcmpi(bk.retbno(),n)==0)
{
bk.show_book();
cout<<"\nEnter The New Details of book"<<endl;
bk.modify_book();
int pos=-1*sizeof(bk);
fp.seekp(pos,ios::cur);
fp.write((char*)&bk,sizeof(book));
cout<<"\n\n\t Record Updated";
found=1;
}
}
fp.close();
if(found==0)
cout<<"\n\n Record Not Found ";
getch();
}
void modify_student()
{
char n[6];
int found=0;
clrscr();
cout<<"\n\n\tMODIFY STUDENT RECORD... ";
cout<<"\n\n\tEnter The admission no. of The student";
cin>>n;
fp.open("student.dat",ios::in|ios::out);
while(fp.read((char*)&st,sizeof(student)) && found==0)
{
if(strcmpi(st.retadmno(),n)==0)
{
st.show_student();
Library Management System (CSE 4th sem)
cout<<"\nEnter The New Details of student"<<endl;
st.modify_student();
int pos=-1*sizeof(st);
fp.seekp(pos,ios::cur);
fp.write((char*)&st,sizeof(student));
cout<<"\n\n\t Record Updated";
found=1;
}
}
fp.close();
if(found==0)
cout<<"\n\n Record Not Found ";
getch();
}
//***************************************************************
// function to delete record of file
//****************************************************************
void delete_student()
{
char n[6];
int flag=0;
clrscr();
cout<<"\n\n\n\tDELETE STUDENT...";
cout<<"\n\nEnter The admission no. of the Student You Want To Delete : ";
cin>>n;
fp.open("student.dat",ios::in|ios::out);
fstream fp2;
fp2.open("Temp.dat",ios::out);
fp.seekg(0,ios::beg);
while(fp.read((char*)&st,sizeof(student)))
{
if(strcmpi(st.retadmno(),n)!=0)
fp2.write((char*)&st,sizeof(student));
else
flag=1;
}
Library Management System (CSE 4th sem)
fp2.close();
fp.close();
remove("student.dat");
rename("Temp.dat","student.dat");
if(flag==1)
cout<<"\n\n\tRecord Deleted ..";
else
cout<<"\n\nRecord not found";
getch();
}
void delete_book()
{
char n[6];
clrscr();
cout<<"\n\n\n\tDELETE BOOK ...";
cout<<"\n\nEnter The Book no. of the Book You Want To Delete : ";
cin>>n;
fp.open("book.dat",ios::in|ios::out);
fstream fp2;
fp2.open("Temp.dat",ios::out);
fp.seekg(0,ios::beg);
while(fp.read((char*)&bk,sizeof(book)))
{
if(strcmpi(bk.retbno(),n)!=0)
{
fp2.write((char*)&bk,sizeof(book));
}
}
fp2.close();
fp.close();
remove("book.dat");
rename("Temp.dat","book.dat");
cout<<"\n\n\tRecord Deleted ..";
getch();
}
void display_alls()
{
clrscr();
fp.open("student.dat",ios::in);
if(!fp)
{
cout<<"ERROR!!! FILE COULD NOT BE OPEN ";
getch();
return;
}
cout<<"\n\n\t\tSTUDENT LIST\n\n";
cout<<"=====================================================
=============\n";
cout<<"\tAdmission No."<<setw(10)<<"Name"<<setw(20)<<"Book
Issued\n";
cout<<"=====================================================
=============\n";
while(fp.read((char*)&st,sizeof(student)))
{
st.report();
}
fp.close();
getch();
}
//***************************************************************
// function to display Books list
//****************************************************************
Library Management System (CSE 4th sem)
void display_allb()
{
clrscr();
fp.open("book.dat",ios::in);
if(!fp)
{
cout<<"ERROR!!! FILE COULD NOT BE OPEN ";
getch();
return;
}
cout<<"\n\n\t\tBook LIST\n\n";
cout<<"=====================================================
====================\n";
cout<<"Book Number"<<setw(20)<<"Book
Name"<<setw(25)<<"Author\n";
cout<<"=====================================================
====================\n";
while(fp.read((char*)&bk,sizeof(book)))
{
bk.report();
}
fp.close();
getch();
}
//***************************************************************
// function to issue book
//****************************************************************
void book_issue()
{
char sn[6],bn[6];
int found=0,flag=0;
Library Management System (CSE 4th sem)
clrscr();
cout<<"\n\nBOOK ISSUE ...";
cout<<"\n\n\tEnter The student's admission no.";
cin>>sn;
fp.open("student.dat",ios::in|ios::out);
fp1.open("book.dat",ios::in|ios::out);
while(fp.read((char*)&st,sizeof(student)) && found==0)
{
if(strcmpi(st.retadmno(),sn)==0)
{
found=1;
if(st.rettoken()==0)
{
cout<<"\n\n\tEnter the book no. ";
cin>>bn;
while(fp1.read((char*)&bk,sizeof(book))&& flag==0)
{
if(strcmpi(bk.retbno(),bn)==0)
{
bk.show_book();
flag=1;
st.addtoken();
st.getstbno(bk.retbno());
int pos=-1*sizeof(st);
fp.seekp(pos,ios::cur);
fp.write((char*)&st,sizeof(student));
cout<<"\n\n\t Book issued
successfully\n\nPlease Note: Write the current date
in backside of your book and submit within 15 days fine Rs. 1 for
each day after 15 days period";
}
}
if(flag==0)
cout<<"Book no does not exist";
}
else
cout<<"You have not returned the last book ";
}
}
Library Management System (CSE 4th sem)
if(found==0)
cout<<"Student record not exist...";
getch();
fp.close();
fp1.close();
}
//***************************************************************
// function to deposit book
//****************************************************************
void book_deposit()
{
char sn[6],bn[6];
int found=0,flag=0,day,fine;
clrscr();
cout<<"\n\nBOOK DEPOSIT ...";
cout<<"\n\n\tEnter The student’s admission no.";
cin>>sn;
fp.open("student.dat",ios::in|ios::out);
fp1.open("book.dat",ios::in|ios::out);
while(fp.read((char*)&st,sizeof(student)) && found==0)
{
if(strcmpi(st.retadmno(),sn)==0)
{
found=1;
if(st.rettoken()==1)
{
while(fp1.read((char*)&bk,sizeof(book))&& flag==0)
{
if(strcmpi(bk.retbno(),st.retstbno())==0)
{
bk.show_book();
flag=1;
cout<<"\n\nBook deposited in no. of days";
cin>>day;
if(day>15)
{
fine=(day-15)*1;
cout<<"\n\nFine has to deposited Rs. "<<fine;
Library Management System (CSE 4th sem)
}
st.resettoken();
int pos=-1*sizeof(st);
fp.seekp(pos,ios::cur);
fp.write((char*)&st,sizeof(student));
cout<<"\n\n\t Book deposited successfully";
}
}
if(flag==0)
cout<<"Book no does not exist";
}
else
cout<<"No book is issued..please check!!";
}
}
if(found==0)
cout<<"Student record not exist...";
getch();
fp.close();
fp1.close();
}
//***************************************************************
// INTRODUCTION FUNCTION
//****************************************************************
void intro()
{
clrscr();
gotoxy(35,11);
cout<<"LIBRARY";
gotoxy(35,14);
cout<<"MANAGEMENT";
gotoxy(35,17);
cout<<"SYSTEM";
cout<<"\n\nMADE BY : YOUR NAME";
cout<<"\n\nSCHOOL : SCHOOL NAME";
Library Management System (CSE 4th sem)
getch();
}
//***************************************************************
// ADMINISTRATOR MENU FUNCTION
//****************************************************************
void admin_menu()
{
clrscr();
int ch2;
cout<<"\n\n\n\tADMINISTRATOR MENU";
cout<<"\n\n\t1.CREATE STUDENT RECORD";
cout<<"\n\n\t2.DISPLAY ALL STUDENTS RECORD";
cout<<"\n\n\t3.DISPLAY SPECIFIC STUDENT RECORD ";
cout<<"\n\n\t4.MODIFY STUDENT RECORD";
cout<<"\n\n\t5.DELETE STUDENT RECORD";
cout<<"\n\n\t6.CREATE BOOK ";
cout<<"\n\n\t7.DISPLAY ALL BOOKS ";
cout<<"\n\n\t8.DISPLAY SPECIFIC BOOK ";
cout<<"\n\n\t9.MODIFY BOOK ";
cout<<"\n\n\t10.DELETE BOOK ";
cout<<"\n\n\t11.BACK TO MAIN MENU";
cout<<"\n\n\tPlease Enter Your Choice (1-11) ";
cin>>ch2;
switch(ch2)
{
case 1: clrscr();
write_student();break;
case 2: display_alls();break;
case 3:
char num[6];
clrscr();
cout<<"\n\n\tPlease Enter The Admission No. ";
cin>>num;
display_sps(num);
break;
case 4: modify_student();break;
Library Management System (CSE 4th sem)
case 5: delete_student();break;
case 6: clrscr();
write_book();break;
case 7: display_allb();break;
case 8: {
char num[6];
clrscr();
cout<<"\n\n\tPlease Enter The book No. ";
cin>>num;
display_spb(num);
break;
}
case 9: modify_book();break;
case 10: delete_book();break;
case 11: return;
default:cout<<"\a";
}
admin_menu();
}
//***************************************************************
// THE MAIN FUNCTION OF PROGRAM
//****************************************************************
void main()
{
char ch;
intro();
do
{
clrscr();
cout<<"\n\n\n\tMAIN MENU";
cout<<"\n\n\t01. BOOK ISSUE";
cout<<"\n\n\t02. BOOK DEPOSIT";
cout<<"\n\n\t03. ADMINISTRATOR MENU";
cout<<"\n\n\t04. EXIT";
cout<<"\n\n\tPlease Select Your Option (1-4) ";
ch=getche();
Library Management System (CSE 4th sem)
switch(ch)
{
case '1':clrscr();
book_issue();
break;
case '2':book_deposit();
break;
case '3':admin_menu();
break;
case '4':exit(0);
default :cout<<"\a";
}
}while(ch!='4');
}
//***************************************************************
// END OF PROJECT
//***************************************************************
7
Library Management System (CSE 4th sem)
RESULT
This is the first page that has been used to show the user and his/her College name.
When the user will enter its choice it will be display the related information to the user. The
following are all the outputs of the user’s choice related outputs.
Now diplays the message that record has been updated successfully.
If you have to enter a new book into the library then it also edits a new book by the book no’.
If you want to change something in a record then it will also ask user the book no’ and by this we
can update the record of the book.
8.1CONCLUSION
After we have completed the project we are sure the problems in the existing system would
human errors and to increase the efficiency. The main focus of this project is to lessen human
efforts. The navigation control is provided in all the forms to navigate through the large amount of
records. If the numbers of records are very large then user has to just type in the search string and
user gets the results immediately. The editing is also made simpler. The user has to just type in the
The Books and Students are given a particular unique id no. So that they can be accessed correctly
and without errors. Our main aim of the project is to get the correct information about a particular
The problems, which existed in the earlier system, have been removed to a large extent. And it is
expected that this project will go a long way in satisfying users requirements. The computerization
of the Library Management will not only improves the efficiency but will also reduce human stress
This application can be easily implemented under various situations. We can add new features as
and when we require. Reusability is possible as and when require in this application. There is
flexibility in all the modules.
SOFTWARE SCOPE
• Extensibility: This software is extendable in ways that its originaldevelopers may not expect.
The following principles enhance sentensibility like hide data structure, avoid traversing multiple
links or methods, avoid case statements on object type and distinguish public and private
operations.
• Reusability: Reusability is possible as and when require in this application. We can update it
next version. Reusable software reduces design, coding and testing cost by amortizing effort over
several designs. Reducing the amount of code also simplifies understanding, which increases the
likelihood that the code is correct.
• Understandability: A method is understandable if someone other than the creator of the method
can understand the code (as well as the creator after a time lapse). We use the method,
which small and coherent helps to accomplish this.
• Cost-effectiveness: Its cost is under the budget and make within given time period. It is desirable
to aim for a system with a minimum cost subject to the condition that it must satisfy the
entire requirement.Scope of this document is to put down the requirements, clearly identifying the
information needed by the user, the source of the information and outputs expected from the
system.
8.3DRAWBACKS
9
Library Management System (CSE 4th sem)
REFERENCES AND BIBLIOGRAPHY
9.1REFERENCES
www.google.com
www.sourcecodeworld.com
www.microsoft.com
www.qsee-technologies.com
9.2BIBLIOGRAPHY