1. Employee Management System
A Minor Project
On
Employee Management and Payroll System
Submitted in Partial fulfillment for the award of
Bachelor of Engineering
Submitted to
RAJIV GANDHI PROUDYOGIKI VISHWAVIDHYALAYA
BHOPAL (M.P.)
Submitted By:
Aayushmaan Gupta - 0133CS091001
Prateek Sharma - 0133CS091073
PradeepPawar - 0133CS091069
Naveen Singh - 0133CS091056
Under The Supervision of
Prof Brijkishore Gupta / Prof Mayank
DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING
SAGAR INSTITUTE OF RESEARCH & TECHNOLOGY, BHOPAL
Sagar Institute of Research and Technology Page 1
2. Employee Management System
SAGAR INSTITUTE OF RESEARCH & TECHNOLOGY,
BHOPAL
DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING
CERTIFICATE
This is to certify that the work embodied in this report entitled Topic has been
satisfactorily completed by Student name. It is a bonafide piece of work, carried
out under our/my guidance in the Department of Computer Science & Engineering,
Sagar Institute of Research & Technology, and Bhopal for the partial fulfillment of
the Bachelor of Engineering during the academic year 2011-2012.
Project Guide: HOD: Director:
Prof. Brijkishore Gupta Prof. MeghaKamble Dr. S.C. Bhageria
Sagar Institute of Research and Technology Page 2
3. Employee Management System
SAGAR INSTITUTE OF RESEARCH & TECHNOLOGY,
BHOPAL
DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING
SELF CERTIFICATE
This to certify that the project report entitled “Employee ManagementSystem” is
done by us is an authentic work carried out for the partialfulfillment of the
requirements for the award of the degree Bachelor of Engineering, under the
guidance of Prof.Brijkishore Gupta.
Name of the studentRoll No. Signature ofthestudent
1. Aayushmaan Gupta 0133CS091001
2. Prateek Sharma 0133CS091073
3. PradeepPawar 0133CS091069
4. Naveen Singh 0133CS091056
Sagar Institute of Research and Technology Page 3
4. Employee Management System
SAGAR INSTITUTE OF RESEARCH & TECHNOLOGY,
BHOPAL
ACKNOWLEDGEMENT
The austerity and satisfaction that one gets oncompleting a project cannot be
fulfilled withoutmentioning the people who made it possible, withgratitude, we are
very much thankful to the AlmightyGod who helped us all the way throughout the
projectand who has molded us into what we are today.
We are privileged to express our sinceregratitude to honorable Dr. S.C. Bhageria,
Director, SIRT, and Bhopal for allencouragement he gave us.
We express our sincerethanks and gratitude to Prof. MeghaKamble(H.O.D.) of
Computer Science for all his valuablesuggestions and guidance throughout our
project.
We wish to express our hearty gratitude to our internal project guide, Pro.
Brijkishore Gupta for hisvaluable suggestions and guidance throughout thetenure
of our project.
We extend our sincere thanks toall the college staff members who helped us
tocomplete this project successfully.
Sagar Institute of Research and Technology Page 4
5. Employee Management System
TABLE OF CONTENTS
S.No. HEADING PAGE No.
1. Introduction 6
1.1 Purpose / objective 6
1.2 Study of existing System / Scope of new System 6
1.3 Software Requirements 7
1.4 Hardware Requirements 8
2. Analysis 9
2.1 Study Of Proposed System 9
2.2 Problem Definition 9
2.3 Solution Strategies 9
3. Designing 10
3.1 Data Flow Diagram 10
3.2 E-R Diagram 11
3.3 Database Design 13
3.4 Use Case Diagram 15
4 Coding 16
5. Front End Forms/screens 42
6 Testing 48
6.1 System testing 48
6.2 Test cases 50
7 Limitations & Future Enhancements 51
8 Conclusion 52
9 Bibliography & References 53
Sagar Institute of Research and Technology Page 5
6. Employee Management System
CHAPTER - 1
INTRODUCTION
Employee management and payroll system is the modern computer based record
management system of employees of any firm. Since it would be very difficult for
any firm to maintain the records of employee on the papers and keep their
attendance records also, we tried to convert this manpower to computer power. It is
found that this is very efficient way to manage records as well as attendance record
through this system.
1.1 Purpose / Objective:
The main goal of this project is to make the recordof employee’s easier & quicker.
It is situated for all level of peoples.
It provides proper details about the entire employee & their posts.
User friendly environment makes the data handling more easily.
It easily provides an environment where the user can get information
aboutall the employees/worker
1.2 Study of existing System:
Exiting EMS is based on the standalone system.
It is developed on the access 95 hence it is not compatible on modern
operating system.
Existing EMS is not user friendly.
It is not provided with the detailed project information done or to be
assigned based on the application.
It needs extra manual power also.
Scope of new System:
It is user friendly, can be accessed by any one.
It has user id and password system to maintain privacy and security.
It is very fast and accurate.
No need of extra manual effort.
Just need little knowledge to operate the system.
Doesn’t require any extra hardware device.
Sagar Institute of Research and Technology Page 6
7. Employee Management System
1.3 Software requirements:
Operating System: Windows XP or higher.
Front End tool : Visual Basic 6.0.
Back End tool : Oracle 10g.
Software Justification:
Operating System: As now a day’s windows XP or higher are more common
in market, we have designed this software to support all these OS.
Front End tool:
Visual Basic 6.0: Microsoft Visual Basic 6.0 is the powerful programming
language to develop applicationfor windows. Windows is the operating
system, which runs based on messages and with rich user interface.
Back End tool:
Oracle 10g: Oracle 10g is very easy to understand and easily
programmable. It provides easy database storage also; hence we have used this to
store data in form of table of our software.
Sagar Institute of Research and Technology Page 7
8. Employee Management System
1.4 Hardware Requirements:
The configuration given below isthe Hardwarehandled for the systemdevelopment.
Processor : PENTIUM IV or Above
Primary Memory (RAM) : 256 MB or Above
Secondary Memory (Hard disk) : 20 GB or Above
Monitor : COLOR, 15inch or above
Display card : SVGA
Mouse& Keyboard : Any Company
Cabinet : Mini tower ATX
These above hardware requirements are now a days very common and can be
found on any computer system. It is kept in mind while designing that no extra
hardware support which can be needed to run the software should be there so that it
can be afforded by any firm or industry.
CHAPTER - 2
Sagar Institute of Research and Technology Page 8
9. Employee Management System
ANALYSIS
2.1Study of the proposed system:
This system consists of different tablewhich contains the record of employees & it
is commented through VB which is thefront end. In VB we have seen the
information about the employee. You can also provide the different buttons like,
add, delete, edit, exit etc. which helps you to editany data & make your work
easier.
2.2Problem definition:
In the old system the main task of editing is not done easily& it will also take
time.But in the proposed system the main assumptions are, thesystem should
already contains all the hardware’s & software’s as well as theperson who use this
product should familiar with window XP or any operatingsystem.
2.3 Solution strategies:
The main solution of the problem is to provide suitable &user friendly
environment to a user so that the user can maintain the detail of employee in a very
easy manner.
2.4 Cost Estimation andScheduling
Project estimation and scheduling were carried out together by the project leader
asper the norms of the company. Some cost estimation was done at the early
stagebefore the schedules were drawn up. Once the project was underway,
estimateswere updated. The factors involved in computing the total cost of a
software projectwere Hardware & software cost, Maintenance cost, Travel and
training cost and Effort cost.Scheduling as well as estimating the effort required to
develop the software systemwas done by the project leader in discussion with the
Company officials.
CHAPTER – 3
Sagar Institute of Research and Technology Page 9
10. Employee Management System
DESIGNING
3.1 Data Flow Diagram:
Report 1
Login
Personal Details Attendance Details
Employee Details
Professional Details Salary Details
Report 2
Report 3
Sagar Institute of Research and Technology Page 10
11. Employee Management System
3.2 E-R Diagram:
1) Login Form:
User ID Password
Login
2) Personal Details:
EMP Name
EMP No. Sex
Personal Details
Address
Date of Birth
City
Sagar Institute of Research and Technology Page 11
12. Employee Management System
3) Professional Details:
Date of Join Designation
EMP ID Department
Profession Details
4) Salary details:
GIS
PF CCA
Basic Sal HRA
Salary Details
Inc. TAX DA
NET GROSS
Sagar Institute of Research and Technology Page 12
13. Employee Management System
5) Attendance Details:
Sick Leaves
Casual Leaves
Year
Other Leaves
For Month
EMP. ID Total Leaves
Attendance Details
3.3 Database design:
1) Add Employee Database Details:
Field Name Data Type Size
Employee number Number 4
Employee Name Varchar2 30
Sex Varchar2 1
Address Varchar2 30
City Varchar2 20
Date Of Birth Date
Date Of Join Date
Designation Varchar2 20
Department Varchar2 15
Sagar Institute of Research and Technology Page 13
14. Employee Management System
2) Salary Details Database Design:
Field Data Type Size
Basic Number (7,2)
Provident Fund Number (6,2)
Group Insurance Scheme Number (6,2)
City Compensatory Allowance Number (6,2)
House rent Allowance Number (6,2)
Dearness Allowance Number (6,2)
Gross Number (7,2)
Income tax Number (7,2)
Net Salary Number (7,2)
3) Attendance table Database Design:
Field Data Type Size
Employee Number Number 4
For Month Number 2
Year Number 4
Casual Leaves Number 2
Sick Leaves Number 2
Other Leaves Number 2
Total Leaves Number 2
Sagar Institute of Research and Technology Page 14
15. Employee Management System
3.4 Use Case Diagram:
Add EMP
Modify EMP
Emp Information
Manager
Delete EMP
Display EMP
Enter Att
Attendance
Processing
Display Att
Salary
Statement of
EMP
Reporting
EMP
Department
wise List
Sagar Institute of Research and Technology Page 15
16. Employee Management System
CHAPTER– 4
CODING
4.1 Login Form Code:
Private Sub Command1_Click()
If Text1.Text = ("admin") And Text2.Text = ("skyworld") Then
welcome.Show
Me.Hide
Else
MsgBox "Sorry Enter a right user name and password !!!!"
End If
End Sub
Private Sub Command2_Click()
If (MsgBox("Are You Sure You Want to Exit EMS?", vbYesNo + vbQuestion, "Quit") = vbYes)
Then
End
End If
End Sub
Private Sub Command3_Click()
welcome.Show
Me.Hide
Unload login
End Sub
Sagar Institute of Research and Technology Page 16
17. Employee Management System
4.2 Welcome For (MDI Form) Code:
Private Sub MDIForm_Load()
Me.WindowState = vbMaximized
End Sub
Private Sub mnuAPdis_Click()
Load disAtt
disAtt.Show
End Sub
Private Sub mnuAPenter_Click()
Load frmAddAtt
frmAddAtt.Show
End Sub
Private Sub mnuEPadd_Click()
Load addemp
addemp.Show
End Sub
Private Sub mnuEPdele_Click()
Load delemp
delemp.Show
End Sub
Private Sub mnuEPdis_Click()
Sagar Institute of Research and Technology Page 17
18. Employee Management System
Load disemp
disemp.Show
End Sub
Private Sub mnuEPmod_Click()
Load modemp
modemp.Show
End Sub
Private Sub mnuExit_Click()
If (MsgBox("Are You Sure You Want to Exit EMS?", vbYesNo + vbQuestion, "Quit") = vbYes)
Then
End
End If
End Sub
Private Sub mnuHelp_Click()
Load help
help.Show
End Sub
Private Sub mnuRep1_Click()
DataReport1.Show
End Sub
Private Sub mnuRepPrn_Click()
Sagar Institute of Research and Technology Page 18
19. Employee Management System
DataReport1.PrintReport
End Sub
Private Sub mnuREPsalmon_Click()
Load saldis
saldis.Show
End Sub
4.3 Add Employee form Code:
Private Sub save_Click()
adoRSaddemp.Update
adoRSaddemp.Fields("pf") = 0.12 * adoRSaddemp.Fields("basic")
adoRSaddemp.Fields("gis") = 0.05 * adoRSaddemp.Fields("basic")
adoRSaddemp.Fields("cca") = 1000
If adoRSaddemp.Fields("basic") < 10000 Then
adoRSaddemp.Fields("hra") = 3500
Else
If adoRSaddemp.Fields("basic") < 20000 Then
adoRSaddemp.Fields("hra") = 3750
Else
If adoRSaddemp.Fields("basic") < 30000 Then
adoRSaddemp.Fields("hra") = 4200
Else
If adoRSaddemp.Fields("basic") < 40000 Then
adoRSaddemp.Fields("hra") = 4700
Else
adoRSaddemp.Fields("hra") = 5000
Sagar Institute of Research and Technology Page 19
20. Employee Management System
End If
End If
End If
End If
If adoRSaddemp.Fields("basic") < 20000 Then
adoRSaddemp.Fields("da") = 1500
Else
If adoRSaddemp.Fields("basic") < 40000 Then
adoRSaddemp.Fields("da") = 3000
Else
adoRSaddemp.Fields("da") = 4000
End If
End If
adoRSaddemp.Fields("gross") = adoRSaddemp.Fields("basic") + adoRSaddemp.Fields("cca") +
adoRSaddemp.Fields("hra") + adoRSaddemp.Fields("da")
If adoRSaddemp.Fields("gross") > 25000 Then
adoRSaddemp.Fields("it") = 0.25 * adoRSaddemp.Fields("gross")
Else
If adoRSaddemp.Fields("gross") > 17000 Then
adoRSaddemp.Fields("it") = 0.2 * adoRSaddemp.Fields("gross")
Else
If adoRSaddemp.Fields("gross") > 10000 Then
adoRSaddemp.Fields("it") = 0.1 * adoRSaddemp.Fields("gross")
Else: adoRSaddemp.Fields("it") = 0
End If
End If
Sagar Institute of Research and Technology Page 20
21. Employee Management System
End If
adoRSaddemp.Fields("net") = adoRSaddemp.Fields("gross") - adoRSaddemp.Fields("pf") -
adoRSaddemp.Fields("gis") - adoRSaddemp.Fields("it")
adoRSaddemp.Update
MsgBox ("Record Successfully Added In Table")
End Sub
Private Sub exit_Click()
Me.Hide
Unload addemp
End Sub
Private Sub back_Click()
welcome.Show
Unload addemp
End Sub
Private Sub Form_Load()
Combo1.AddItem "CS"
Combo1.AddItem "Mechanical"
Combo1.AddItem "EC"
Combo1.AddItem "Civil"
Combo1.AddItem "Electrical"
Combo1.AddItem "IT"
Set adoConn = New ADODB.Connection
Sagar Institute of Research and Technology Page 21
22. Employee Management System
adoConn.ConnectionString = "Provider=MSDAORA.1;Password=tiger;User ID=scott;Data
Source=ORCL;Persist Security Info=True"
adoConn.CursorLocation = adUseClient
adoConn.Open
Set adoRSaddemp = New ADODB.Recordset
adoRSaddemp.CursorType = adOpenDynamic
adoRSaddemp.LockType = adLockOptimistic
adoRSaddemp.Open "addemp", adoConn, , , adCmdTable
Set empno.DataSource = adoRSaddemp
empno.DataField = "empno"
Set ename.DataSource = adoRSaddemp
ename.DataField = "ename"
Set sex.DataSource = adoRSaddemp
sex.DataField = "sex"
Set address.DataSource = adoRSaddemp
address.DataField = "address"
Set city.DataSource = adoRSaddemp
city.DataField = "city"
Set dob.DataSource = adoRSaddemp
dob.DataField = "dob"
Set doj.DataSource = adoRSaddemp
doj.DataField = "doj"
Set desig.DataSource = adoRSaddemp
desig.DataField = "designation"
Set Combo1.DataSource = adoRSaddemp
Combo1.DataField = "deaprtment"
Sagar Institute of Research and Technology Page 22
23. Employee Management System
Set basic.DataSource = adoRSaddemp
basic.DataField = "basic"
Set pf.DataSource = adoRSaddemp
pf.DataField = "pf"
Set gis.DataSource = adoRSaddemp
gis.DataField = "gis"
Set cca.DataSource = adoRSaddemp
cca.DataField = "cca"
Set hra.DataSource = adoRSaddemp
hra.DataField = "hra"
Set da.DataSource = adoRSaddemp
da.DataField = "da"
Set gross.DataSource = adoRSaddemp
gross.DataField = "gross"
Set it.DataSource = adoRSaddemp
it.DataField = "it"
Set net.DataSource = adoRSaddemp
net.DataField = "net"
End Sub
Private Sub new_Click()
adoRSaddemp.AddNew
End Sub
Sagar Institute of Research and Technology Page 23
24. Employee Management System
4.4 Modify Employee Form Code:
Private Sub exit_Click()
Me.Hide
Unload modemp
End Sub
Private Sub Form_Load()
Combo1.AddItem "CS"
Combo1.AddItem "Mechanical"
Combo1.AddItem "EC"
Combo1.AddItem "Civil"
Combo1.AddItem "Electrical"
Combo1.AddItem "IT"
Set adoConn = New ADODB.Connection
adoConn.ConnectionString = "Provider=MSDAORA.1;Password=tiger;User ID=scott;Data
Source=ORCL;Persist Security Info=True"
adoConn.CursorLocation = adUseClient
adoConn.Open
Set adoRSaddemp = New ADODB.Recordset
adoRSaddemp.CursorType = adOpenDynamic
adoRSaddemp.LockType = adLockOptimistic
adoRSaddemp.Open "addemp", adoConn, , , adCmdTable
Set empno.DataSource = adoRSaddemp
empno.DataField = "empno"
Set ename.DataSource = adoRSaddemp
ename.DataField = "ename"
Sagar Institute of Research and Technology Page 24
25. Employee Management System
Set sex.DataSource = adoRSaddemp
sex.DataField = "sex"
Set address.DataSource = adoRSaddemp
address.DataField = "address"
Set city.DataSource = adoRSaddemp
city.DataField = "city"
Set dob.DataSource = adoRSaddemp
dob.DataField = "dob"
Set doj.DataSource = adoRSaddemp
doj.DataField = "doj"
Set desig.DataSource = adoRSaddemp
desig.DataField = "designation"
Set Combo1.DataSource = adoRSaddemp
Combo1.DataField = "deaprtment"
Set basic.DataSource = adoRSaddemp
basic.DataField = "basic"
Set pf.DataSource = adoRSaddemp
pf.DataField = "pf"
Set gis.DataSource = adoRSaddemp
gis.DataField = "gis"
Set cca.DataSource = adoRSaddemp
cca.DataField = "cca"
Set hra.DataSource = adoRSaddemp
hra.DataField = "hra"
Set da.DataSource = adoRSaddemp
da.DataField = "da"
Sagar Institute of Research and Technology Page 25
26. Employee Management System
Set gross.DataSource = adoRSaddemp
gross.DataField = "gross"
Set it.DataSource = adoRSaddemp
it.DataField = "it"
Set net.DataSource = adoRSaddemp
net.DataField = "net"
Dim flag As Integer
Dim eno As Integer
flag = 0
eno = InputBox("Enter the employee number to be Modified", "Employee Number", 0)
adoRSaddemp.MoveFirst
Do While adoRSaddemp.EOF = False
If adoRSaddemp.Fields("empno") <>eno Then
adoRSaddemp.MoveNext
Else
flag = 1
Exit Do
End If
Loop
If flag = 0 Then
MsgBox ("Employee number does not exists")
End If
End Sub
Private Sub save_Click()
adoRSaddemp.Update
Sagar Institute of Research and Technology Page 26
27. Employee Management System
adoRSaddemp.Fields("pf") = 0.12 * adoRSaddemp.Fields("basic")
adoRSaddemp.Fields("gis") = 0.05 * adoRSaddemp.Fields("basic")
adoRSaddemp.Fields("cca") = 1000
If adoRSaddemp.Fields("basic") < 10000 Then
adoRSaddemp.Fields("hra") = 3500
Else
If adoRSaddemp.Fields("basic") < 20000 Then
adoRSaddemp.Fields("hra") = 3750
Else
If adoRSaddemp.Fields("basic") < 30000 Then
adoRSaddemp.Fields("hra") = 4200
Else
If adoRSaddemp.Fields("basic") < 40000 Then
adoRSaddemp.Fields("hra") = 4700
Else
adoRSaddemp.Fields("hra") = 5000
End If
End If
End If
End If
If adoRSaddemp.Fields("basic") < 20000 Then
adoRSaddemp.Fields("da") = 1500
Else
If adoRSaddemp.Fields("basic") < 40000 Then
adoRSaddemp.Fields("da") = 3000
Else
Sagar Institute of Research and Technology Page 27
28. Employee Management System
adoRSaddemp.Fields("da") = 4000
End If
End If
adoRSaddemp.Fields("gross") = adoRSaddemp.Fields("basic") + adoRSaddemp.Fields("cca") +
adoRSaddemp.Fields("hra") + adoRSaddemp.Fields("da")
If adoRSaddemp.Fields("gross") > 25000 Then
adoRSaddemp.Fields("it") = 0.25 * adoRSaddemp.Fields("gross")
Else
If adoRSaddemp.Fields("gross") > 17000 Then
adoRSaddemp.Fields("it") = 0.2 * adoRSaddemp.Fields("gross")
Else
If adoRSaddemp.Fields("gross") > 10000 Then
adoRSaddemp.Fields("it") = 0.1 * adoRSaddemp.Fields("gross")
Else: adoRSaddemp.Fields("it") = 0
End If
End If
End If
adoRSaddemp.Fields("net") = adoRSaddemp.Fields("gross") - adoRSaddemp.Fields("pf") -
adoRSaddemp.Fields("gis") - adoRSaddemp.Fields("it")
adoRSaddemp.Update
MsgBox ("Record Successfully Modified In Table")
End Sub
4.5 Delete Employee From Code:
Dim flag As Integer
Private Sub delete_Click()
If (MsgBox(" Are you sure you want to delete this record?", vbYesNo) = vbYes) Then
Sagar Institute of Research and Technology Page 28
29. Employee Management System
adoRSaddemp.delete
adoRSaddemp.Update
MsgBox ("Record Successfully Deleted in table!!!")
End If
End Sub
Private Sub exit_Click()
Me.Hide
Unload delemp
End Sub
Private Sub Form_Load()
Set adoConn = New ADODB.Connection
adoConn.ConnectionString = "Provider=MSDAORA.1;Password=tiger;User ID=scott;Data
Source=ORCL;Persist Security Info=True"
adoConn.CursorLocation = adUseClient
adoConn.Open
Set adoRSaddemp = New ADODB.Recordset
adoRSaddemp.CursorType = adOpenDynamic
adoRSaddemp.LockType = adLockOptimistic
adoRSaddemp.Open "addemp", adoConn, , , adCmdTable
Set empno.DataSource = adoRSaddemp
empno.DataField = "empno"
Set ename.DataSource = adoRSaddemp
ename.DataField = "ename"
Set sex.DataSource = adoRSaddemp
Sagar Institute of Research and Technology Page 29
30. Employee Management System
sex.DataField = "sex"
Set address.DataSource = adoRSaddemp
address.DataField = "address"
Set city.DataSource = adoRSaddemp
city.DataField = "city"
Set dob.DataSource = adoRSaddemp
dob.DataField = "dob"
Set doj.DataSource = adoRSaddemp
doj.DataField = "doj"
Set desig.DataSource = adoRSaddemp
desig.DataField = "designation"
Set dep.DataSource = adoRSaddemp
dep.DataField = "deaprtment"
Set basic.DataSource = adoRSaddemp
basic.DataField = "basic"
Set pf.DataSource = adoRSaddemp
pf.DataField = "pf"
Set gis.DataSource = adoRSaddemp
gis.DataField = "gis"
Set cca.DataSource = adoRSaddemp
cca.DataField = "cca"
Set hra.DataSource = adoRSaddemp
hra.DataField = "hra"
Set da.DataSource = adoRSaddemp
da.DataField = "da"
Set gross.DataSource = adoRSaddemp
Sagar Institute of Research and Technology Page 30
31. Employee Management System
gross.DataField = "gross"
Set it.DataSource = adoRSaddemp
it.DataField = "it"
Set net.DataSource = adoRSaddemp
net.DataField = "net"
End Sub
Private Sub search_Click()
Dim empno As Integer
flag = 0
empno = InputBox("Enter the employee number to be deleted", "Employee Number", 0)
adoRSaddemp.MoveFirst
Do While adoRSaddemp.EOF = False
If adoRSaddemp.Fields("empno") <>empno Then
adoRSaddemp.MoveNext
Else
flag = 1
Exit Do
End If
Loop
If flag = 0 Then
MsgBox ("Employee number does not exists")
End If
End Sub
Sagar Institute of Research and Technology Page 31
32. Employee Management System
4.6 Display Employee Form Code:
Private Sub exit_Click()
Me.Hide
Unload disemp
End Sub
Private Sub Form_Load()
Set adoConn = New ADODB.Connection
adoConn.ConnectionString = "Provider=MSDAORA.1;Password=tiger;User ID=scott;Data
Source=ORCL;Persist Security Info=True"
adoConn.CursorLocation = adUseClient
adoConn.Open
Set adoRSaddemp = New ADODB.Recordset
adoRSaddemp.CursorType = adOpenDynamic
adoRSaddemp.LockType = adLockOptimistic
adoRSaddemp.Open "addemp", adoConn, , , adCmdTable
Set empno.DataSource = adoRSaddemp
empno.DataField = "empno"
Set ename.DataSource = adoRSaddemp
ename.DataField = "ename"
Set sex.DataSource = adoRSaddemp
sex.DataField = "sex"
Set address.DataSource = adoRSaddemp
address.DataField = "address"
Set city.DataSource = adoRSaddemp
city.DataField = "city"
Sagar Institute of Research and Technology Page 32
33. Employee Management System
Set dob.DataSource = adoRSaddemp
dob.DataField = "dob"
Set doj.DataSource = adoRSaddemp
doj.DataField = "doj"
Set desig.DataSource = adoRSaddemp
desig.DataField = "designation"
Set dep.DataSource = adoRSaddemp
dep.DataField = "deaprtment"
Set basic.DataSource = adoRSaddemp
basic.DataField = "basic"
Set pf.DataSource = adoRSaddemp
pf.DataField = "pf"
Set gis.DataSource = adoRSaddemp
gis.DataField = "gis"
Set cca.DataSource = adoRSaddemp
cca.DataField = "cca"
Set hra.DataSource = adoRSaddemp
hra.DataField = "hra"
Set da.DataSource = adoRSaddemp
da.DataField = "da"
Set gross.DataSource = adoRSaddemp
gross.DataField = "gross"
Set it.DataSource = adoRSaddemp
it.DataField = "it"
Set net.DataSource = adoRSaddemp
net.DataField = "net"
Sagar Institute of Research and Technology Page 33
34. Employee Management System
Dim flag As Integer
Dim eno As Integer
flag = 0
eno = InputBox("Enter the employee number to be Displayed", "Employee Number", 0)
adoRSaddemp.MoveFirst
Do While adoRSaddemp.EOF = False
If adoRSaddemp.Fields("empno") <>eno Then
adoRSaddemp.MoveNext
Else
flag = 1
Exit Do
End If
Loop
If flag = 0 Then
MsgBox ("Employee number does not exists")
End If
End Sub
4.7Add Attendance Form Code:
Private Sub Command1_Click()
Select Case adoRSattendence.Fields("for_month")
Case 1, 3, 5, 7, 8, 10, 12
DM = 31
Case 4, 6, 9, 11
DM = 30
Case 2
DM = 28
Sagar Institute of Research and Technology Page 34
35. Employee Management System
Case Else
MsgBox ("Wronge month Number.Record Not Saved.")
Exit Sub
End Select
nol = adoRSattendence.Fields("pls") + adoRSattendence.Fields("mls") +
adoRSattendence.Fields("lwp")
If nol> DM Then
MsgBox ("Number of leaves greater then number of days in a month. Record Not saved.")
Exit Sub
End If
total.Text = CInt(pls.Text) + CInt(mls.Text) + CInt(lwp.Text)
adoRSattendence.Update
MsgBox ("Record Updated")
End Sub
Private Sub Command2_Click()
Me.Hide
Unload frmAddAtt
End Sub
Private Sub Form_Load()
Set adoConn = New ADODB.Connection
adoConn.ConnectionString = "Provider=MSDAORA.1;Password=tiger;User ID=scott;Data
Source=ORCL;Persist Security Info=True"
adoConn.CursorLocation = adUseClient
adoConn.Open
Set adoRSattendence = New ADODB.Recordset
Sagar Institute of Research and Technology Page 35
36. Employee Management System
adoRSattendence.CursorType = adOpenDynamic
adoRSattendence.LockType = adLockOptimistic
adoRSattendence.Open "attendence", adoConn, , , adCmdTable
Set empno.DataSource = adoRSattendence
empno.DataField = "Empno"
Set formonth.DataSource = adoRSattendence
formonth.DataField = "for_month"
Set year.DataSource = adoRSattendence
year.DataField = "year"
Set pls.DataSource = adoRSattendence
pls.DataField = "pls"
Set mls.DataSource = adoRSattendence
mls.DataField = "mls"
Set lwp.DataSource = adoRSattendence
lwp.DataField = "lwp"
Set total.DataSource = adoRSattendence
total.DataField = "cls"
End Sub
Private Sub new_Click()
adoRSattendence.AddNew
End Sub
Sagar Institute of Research and Technology Page 36
37. Employee Management System
4.8Display Attendance Form Code:
Private Sub Command3_Click()
Dim empno As Integer
Dim flag As Integer
flag = 0
empno = InputBox("Enter the employee number to show", "Employee number", 0)
adoRSattendence.MoveFirst
Do While adoRSattendence.EOF = False
If adoRSattendence.Fields("empno") <>empno Then
adoRSattendence.MoveNext
Else
flag = 1
Exit Do
End If
Loop
If flag = 0 Then
MsgBox ("Employee number does not exist.")
End If
End Sub
Private Sub exit_Click()
Me.Hide
Unload disAtt
End Sub
Sagar Institute of Research and Technology Page 37
38. Employee Management System
Private Sub Form_Load()
Set adoConn = New ADODB.Connection
adoConn.ConnectionString = "Provider=MSDAORA.1;Password=tiger;User ID=scott;Data
Source=ORCL;Persist Security Info=True"
adoConn.CursorLocation = adUseClient
adoConn.Open
Set adoRSattendence = New ADODB.Recordset
adoRSattendence.CursorType = adOpenDynamic
adoRSattendence.LockType = adLockOptimistic
adoRSattendence.Open "attendence", adoConn, , , adCmdTable
Set empno.DataSource = adoRSattendence
empno.DataField = "Empno"
Set formonth.DataSource = adoRSattendence
formonth.DataField = "for_month"
Set year.DataSource = adoRSattendence
year.DataField = "year"
Set pls.DataSource = adoRSattendence
pls.DataField = "pls"
Set mls.DataSource = adoRSattendence
mls.DataField = "mls"
Set lwp.DataSource = adoRSattendence
lwp.DataField = "lwp"
Set total.DataSource = adoRSattendence
total.DataField = "cls"
End Sub
Sagar Institute of Research and Technology Page 38
39. Employee Management System
Private Sub Next_Click()
If (adoRSattendence.EOF = True) Then
MsgBox ("No more Records !!")
adoRSattendence.MoveFirst
Else
adoRSattendence.MoveNext
End If
End Sub
Private Sub Previous_Click()
If (adoRSattendence.BOF = True) Then
MsgBox ("Beginning Of File !!")
adoRSattendence.MoveLast
Else
adoRSattendence.MovePrevious
End If
End Sub
4.9Salary Statement form Code:
Dim mon As Integer
Dim yrAs Integer
Dim eno As Integer
Dim flag As Integer
Dim flag1 As Integer
Private Sub exit_Click()
Sagar Institute of Research and Technology Page 39
40. Employee Management System
Me.Hide
Unload saldis
End Sub
Private Sub Form_Load()
flag = 0
flag1 = 0
eno = InputBox("Enter 'Employee Number' whose salary slip to be show", "Employee Number",
0)
EMPDE.rsaddemp.MoveFirst
Do While EMPDE.rsaddemp.EOF = False
If EMPDE.rsaddemp.Fields("empno") <>eno Then
EMPDE.rsaddemp.MoveNext
Else
flag = 1
Exit Do
End If
Loop
If flag = 0 Then
MsgBox ("Employee number does not exists.")
Else
mon = InputBox("Enter the 'MONTH' for which salary slip has to be generated", "MONTH", 0)
yr = InputBox("Enter the 'YEAR' for which salary slip has to be generated", "YEAR", 0)
EMPDE.rsattendence.MoveFirst
Do While EMPDE.rsattendence.EOF = False
If EMPDE.rsattendence.Fields("empno") = eno And EMPDE.rsattendence.Fields("for_month")
= mon And EMPDE.rsattendence.Fields("year") = yr Then
Sagar Institute of Research and Technology Page 40
41. Employee Management System
flag1 = 1
Exit Do
Else
EMPDE.rsattendence.MoveNext
End If
Loop
If flag1 = 0 Then
MsgBox ("Employee number does not exists in attendance table.")
End If
End If
If flag = 1 And flag1 = 1 Then
deduction.Text = EMPDE.rsaddemp.Fields("pf") + EMPDE.rsaddemp.Fields("gis") +
EMPDE.rsaddemp.Fields("it")
nol.Text = EMPDE.rsattendence.Fields("cls")
netsal.Text = EMPDE.rsaddemp.Fields("net") - EMPDE.rsattendence.Fields("cls") *
EMPDE.rsaddemp.Fields("basic") / 30
End If
End Sub
Private Sub print_Click()
PrintForm
End Sub
4.10 Module 1 Screen Code
Public adoConn As ADODB.Connection
Public adoRSattendence As ADODB.Recordset
Public adoRSaddemp As ADODB.Recordset
Sagar Institute of Research and Technology Page 41
42. Employee Management System
CHAPTER – 5
FRONTEND FORM SCREENS
5.1 Login Form Screen:
5.2 Welcome Form Screen:
Sagar Institute of Research and Technology Page 42
43. Employee Management System
5.3 Add Employee Screen:
5.4 Modify Employee Screen:
Sagar Institute of Research and Technology Page 43
44. Employee Management System
5.5 Delete Employee Screen:
5.6 Display Employee Screen:
Sagar Institute of Research and Technology Page 44
45. Employee Management System
5.7 Add Attendance Screen:
5.8 Display Attendance Screen:
Sagar Institute of Research and Technology Page 45
47. Employee Management System
5.10 On Screen Department Wise Employee List Screen:
5.11 Help Screen:
Sagar Institute of Research and Technology Page 47
48. Employee Management System
CHAPTER – 6
TESTING
6.1 SYSTEM TESTING
Software testing is a crucial element of software quality assurance and representsthe ultimate
review of specification, design and coding. The increasing visibility of software as a system
element and the attendant "cost" associated with a software failure aremotivating forces for well-
planned, thorough testing. Testing is a set of activities that canbe planned in advance and
conducted systematically. Testing begins at the module leveland work towards the integration of
entire computers based system. Nothing is completewithout testing, as it is vital success of the
system.
Unit Testing
Unit testing focuses on the verification of smallest unit of software design of themodule. To
check whether each module in the software works properly so that it givesdesired outputs to the
given inputs. All validations and conditions are tested in the modulelevel in unit test. Control
paths are tested to ensure the information properly flows into andout of the program unit under
test. Boundary condition are tested to ensure that themodules operates at boundary establishes to
restrict processing. All independent pathsthrough control structure are exercised to ensure that all
statements in a module have beenexecuted at least once. And finally all errors handling paths are
tested.In our system, Unit testing has been successfully handled. The test data was givento each
module in all respects and have got desired output. Each module has been foundworking
properly.
Black Box Testing
Black Box Testing methods focus on the functional requirements of the software. This testing
enables the software engineer to derive sets of input conditions that will fullyexercise all
functional requirements for a program. This testing attempts to find errors inthe following
categories: incorrect or missing functions, interface errors, errors in datastructure or external
database access, performance errors and initialization errors andtermination errors. In our
system, Black Box testing has been successfully handled. Thetest input data was given has got
desired output.
User Acceptance Testing
The performance of user interactive testing is actually the user show. The user gives live data
and checks whether software is giving specified outputs.
Sagar Institute of Research and Technology Page 48
49. Employee Management System
6.1.1SYSTEM IMPLEMENTATION
Implementation is the phase where the system goes for actual functioning. Hence inthis phase
one has to be cautious because all the efforts undertaken during the project willbe fruitful only if
the software is properly implemented according to the plans made.The implementation phase is
less creative than system design. It is primarilyconcerned with user training, site preparation and
file conversion. Depending on the natureof the system, extensive user training may be required.
The initial parameters of the MISshould be modified as the result of programming efforts;
programming provides a realitytest for the assumptions made by the analyst.The system testing
checks the readiness and accuracy of the system to access,update and retrieve data from new
files. Once the programs become available, the test dataare read into the computer and process.
6.1.2SYSTEM MAINTENANCE
We may define Software Maintenance by describing four activities that are undertaken after a
program is released for use.
Corrective Maintenance
The first maintenance activity occurs since it is unreasonable to assume that software testing will
uncover all errors in a large software system. The process of includingthe diagnosis and
correction of one or more errors is called corrective maintenance.
Adaptive Maintenance
This activity that contributes to the definition of maintenance occurs since rapidchange is
encountered in every aspect of computing. Therefore, adaptive maintenancemodifies software to
properly interface with the changing environment.
Perfective Maintenance
This activity involves recommendations for new capabilities, modifications to theexisting
functions and general enhancements whenthe software is used. To satisfy theserequests,
perfective maintenance is performed.
Preventive Maintenance
This activity occurs when software is changed to improve further maintainability or reliability. If
the only available element of a Software Configuration is the source code,maintenance activity
begins with the evaluation of the code, often complicated by poor internal documentation. The
subtle characteristics such as program structure, global datastructure, system interfaces and
performance & design constraints are difficult to hand lead are often misinterpreted. The
amounts of changes that are made to the code aredifficult to access.
Sagar Institute of Research and Technology Page 49
50. Employee Management System
6.2 Test Cases:
1) Test Case 1:
Case : Testing for login Screen.
Result : On testing username and password system was properly taking input.
2) Test Case 2:
Case : Testing for welcome Screen.
Result : On testing Welcome screen the proper results were obtained. The module was going
at proper place on clicking.
3) Test Case 3:
Case :Testing for adding Employee.
Result : The employee was properly added and the fields in the database were properly
saved.
4) Test Case 4:
Case :Testing for Modifying Employee.
Result : The employee was properly modified and the fields in the database were properly
saved after modification.
5) Test Case 5:
Case :Testing for Deleting Employee.
Result : The employee was properly deleted and the fields in the database were properly
deleted.
6) Test Case 6:
Case :Testing for Employee Salary Sheet.
Result : On entering the emp number, month and year the system was properly giving the
salary sheet of the entered employee number and also giving proper deductions.
7) Test Case 7:
Case :Testing for Data Report.
Result : The data report was properly shown with the list of all the employees department
wise with their basic, gross, net salary description.
Sagar Institute of Research and Technology Page 50
51. Employee Management System
CHAPTER – 7
LIMITATIONS AND FURTHER ENHANCEMENTS
Limitations:
Skyworld Tech Employee Management System is limited to our control. Any change or
modification can be done by us only.
It is not an online application or system.
We have not provided any backup system for this.
The system need to run oracle on background.
Further Enhancements:
Search details can be enhanced by detailed identification of searching problems and
rectification steps by company.
This system is entirely designed for STAND ALONE usage, according to the need of
thecustomer if needed the same system can be designed with Network facility to handle
thebranch activities also.
To make this system Online and creating data backups.
Integrated Password management facility can be created.
Sagar Institute of Research and Technology Page 51
52. Employee Management System
SAGAR INSTITUTE OF RESEARCH & TECHNOLOGY,
BHOPAL
DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING
CHAPTER - 8
CONCLUSION
The Employee Management System didn’t automate 100% of their work, but it
isreally a good start to computerize everything and entire Detail can be 100%
computerized.
As far as the work done so far much care was given about the user friendliness and
a verygood interaction with the end users. The interface are so designed and
channeled the userscan never make any mistake while using the application, for an
example while adding new record, user can’t go out without either saving or
canceling the operation, till the timeeither they save or cancel the current operation
all other operations are blocked. There is nochance of making any mistake in the
application.
Sagar Institute of Research and Technology Page 52
53. Employee Management System
SAGAR INSTITUTE OF RESEARCH & TECHNOLOGY,
BHOPAL
DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING
CHAPTER – 9
Bibliography & References
Informatics Practices - SumitaArora
(A Book of Visual Basic)
VB 6 in 21 days - Sams Publishing
IP & My SQL - SumitraArora
For Any assistance Contact:
Aayushmaan Gupta
Mob: +91-9039221551
+91-9407221653
Email: aayushmaan.gbpian@gmail.com
Sagar Institute of Research and Technology Page 53