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 & 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 & 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 student Roll No. Signature ofthestudent

1. Aayushmaan Gupta 0133CS091001

2. Prateek Sharma 0133CS091073

3. PradeepPawar 0133CS091069

4. Naveen Singh 0133CS091056

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.

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

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.

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.

1.4 Hardware Requirements:

The configuration given below istheHardwarehandledforthesystemdevelopment.

Processor : PENTIUM IV or Above

Primary Memory (RAM) : 256MB 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

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

DESIGNING

3.1 Data Flow Diagram:

3.2 E-R Diagram:

1) Login Form:

2) Personal Details:

3) Professional Details:

4) Salary details:

5) 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

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

3.4 Use Case Diagram:

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

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()

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()

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

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

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

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"

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

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"

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"

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

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

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

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

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

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

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"