Вы находитесь на странице: 1из 50

CHAPTER 1

INTRODUCTION

INTRODUCTION

This is a Project work undertaken in context of partial fulfillment of PGDM. I have tried my best to make the complicated process of Hotel Management System as simple as possible using Structured & Modular technique & Menu oriented interface. I have tried to design the software in such a way that user may not have any difficulty in using this package & further expansion is possible without much effort. Even though I cannot claim that this work to be entirely exhaustive, the main purpose of my exercise is perform each .Employees activity in computerized way rather than manually which is time consuming.

I am confident that this software package can be readly used by nonprogramming Personal human handled chance of errors. This project is used by two types of users

1) 2)

Online users Administrator (management of the hotel)

Online users can see the required articles or news Administrator can maintain daily updates in the hotel records. Administrator is must be an authorized user. He can further change the password. There is the facility for password recovery, logout etc

The main aim of the entire activity is to automate the process of day to day activities of Hotel like Room activities, Admission of a New Customer, Assign a room according to customers demand, checkout of a computer and releasing the room and finally compute the bill etc The limited time and resources have restricted us to incorporate, in this project, only a activities that are performed in a HOTEL Management

System, but utmost care has been taken to make the system efficient and user friendly. HOTEL Management System has been designed to computerized the following functions that are performed by the system:

Why VB (Visual Basic)? Visual basic is one of the most popular programming languages in the market today. Microsoft has positioned it to fit multiple purposes in development. The language ranges from light weight vb script programming, to application specific programming with vb for applications What is Visual Basic? The visual part refers to the method used to create GUI. Rather then writing numerous lines of code to describe the appearance and location of interface elements , we simplify add rebuilt objects into place on screens. VB is high level programming language evolved from earlier DOS version called BASIC. VB is event driven programming VB programs are made up of many sub programs , each has its in own program codes and each can be executed independently and at the sane time each can be linked in one way or another. VB is designed to deploy applications across the enterprise and to scale of any size needed the ability to develop object mode is databases integration, server components, and Internet/Intranet applications provides an extensive range of capabilities and tools of the developer. In particular VB lets us to add menus, textboxes, command buttons, option buttons, check boxes, scroll bars, and file & directory boxes to blank windows. We can communicate with other window applications and perhaps most importantly we will have an easy method to let users control and access database.

Advantages of Visual Basic-: VB applications are event driven. Event driven means that the user is in control of applications. The generates the stream of events each time he/she clicks with the mouse or presses key

VB supports the principles of OOD. This means that you can compartmentalize different aspect of application as object & develop & test those object independently

Microsoft has designed VB to be a complete windows application development system.

VB is infinitely extensible through the use of Active X controls, dynamically linked libraries add INS

DATABASE Introduction about Ms-Access: Access has become the best selling database management program because of its combination of power and ease of use. Access is powerful enough that developers can use it to create entire applications that require little or no programming. It also contains an entire programming language, VISUAL BASIC for application which can be used to develop richer and more advance application. Access is easy enough to use that in short time beginner can learn to manage their own data.It is easy for one to get started with access by taking a quick look at its environment and how it is organized.

Access Utilities: Starting Access. Operating a database file. Using the database window to view different access objects. Opening a table in database view and design view. Operating a query database view and design view. Operating a form in form view, database view and design view. Opening a report in the print preview window. Creating new objects. Using the online access help system. Quitting access.

OBJECTIVE
During the past several decades personnel function has be transformed from a relatively obscure record keeping staff to central and top level management function .There are many factors that have influenced this transformation like technological advances, professionalism, and general recognition of human beings as most important resources

A computer based management system is designed to handle all the primary. Information required to calculate monthly statements. Separate database is maintained to handle all the details required for the correct statement calculation and generation.

This project intends to introduce more user friendliness in the various activities such as record updation , maintenance, and searching. The searching of record has been made quite simple as all the details of the customer can be obtained by simply key in the identification of that customer.

Similarly, record maintenance and updation can also be accomplished by using the identification of the customer with all the details being automatically generated. These details are also being promptly automatically updated in the master file thus keeping the record absolutely up-to-date

The entire information has maintained in the database or Files and whoever wants to retrieve cant retrieve, only authorization user can retrieve the necessary information which can b e easily be accessible from the file.

The main objective of the entire activity is to automate the process of day to day activities of Hotel like: 1) 2) 3) 4) 5) 6) Room Activities Admission of a new customer Assign a room according to customer demands Checkout of a computer and releasing the room Finally compute the bill etc. Feedbacks

CHAPTER 2
FEASIBILITY STUDY

FEASIBILITY STUDY:
A feasibility study is carried out to select the best system that must performance requirement and its working ability in an organization. The feasibility of the system has been done in three types:-

Technical Feasibility Study Economical Feasibility Study Behavioral Feasibility Study

1. TECHANICL FEASIBILITY:

Technically we have made feasibility in keeping mind about the hardware so that the designed software can work smoothly with maximum efficiency with the hardware.

2. ECONOMICAL FEASIBILITY:

In this we mainly calculate the cost of proposed system and the cost of customer and compare the cost to meet the users cost. The cost of hardware, facility cost, operating and supply costs are considered. The cost of lightning, A.C. etc.

3. BEHAVIOURAL FEASIBILITY:

We have to consider the cost of staff which has special efforts to educate, sell train on new ways.

S/W & H/W REQUIREMENTS

There are some software and hardware requirements of the software hotel management system.

SOFTWARE REQUIREMENT VB as frontend MS-Access as backend Windows XP and family

HARDWARE REQUIREMENTS: Pentium- 4 processor or latest

40GB or more for data storage

Min 128MB RAM

Printer for reporting and printing

10

CHAPTER 3
SYSTEM ANALYSIS

11

SYSTEM ANALYSIS:
The initial analysis is made by knowing the user requirements. In analysis phase, we have analyzed the users requirement such as:- Addition of the record of the customer who comes into the hotel ,deletion of the record when customer leaves the hotel, printing and calculation of the bill, record of facilities available in the hotel , allotment of the rooms etc. In this project we have also analyzed that the product or software should not be very costly but its quality and interface must be attractive. If any wrong operation is being performed then the software must invoke the operator accordingly.

12

DATA MODULES
In this software we have developed some forms. The brief description about them is as follow

1. LOGIN FORM:

In this form the user will have to enter a username and password. If the password is correct, only then the project will proceed further else an error message will be displayed.

2. MDI FORM:

This is the main form. It contains following fields:-

Check in

Check out

Facilities

On moving the cursor to any of the above fields, drop down menus will be displayed user can click on any of the options available.

13

PROCESS FLOW DIAGRAM

LOGIN
Validity of the user is checked

constraint

Username Password

input

LOGIN

output

MDI Form is displayed

database

login table

MDI FORM

MDI FORM

File New user Change password Exit

Master entry Room Details Customer Details

Booking Room Cab Conference hall

Facility Swimming pool

Bill

14

NEW USER

Id should be unique Password should not more than 10 chracter Constraints Unique id Password database login table input

NEW USER

output

New user is created

CHANGE PASSWORD
Old password and new password should be same constraints Old password New password Confirmed password input

CHANGE PASSWORD
database login table

output

Password is changed

15

EXIT

No input

EXIT

Exit

MASTER ENTRY

MASTER ENTRY

ROOM DETAILS

CUSTOMER DETAILS

16

ROOM DETAILS
Room number should be integer type Room number should not be left blank

Room no. Room type Room capacity A.C & Non A.C input

constraints

ROOM DETAILS

output

Room information is maintained

database Room table

CUSTOMER DETAILS

Customer id should be unique Customer name should not be left blank Contact no. must be numerical and not more than 10 digit Customer name Customer id Contact number Age Gender Address database cust table input Age must be integer constraints

CUSTOMER DETAILS

output

Customer information is maintained

17

BOOKING BOOKING

ROOM BOOKING

CAB BOOKING

CONFERENCE HALL BOOKING

ROOM BOOKING
Room details should not be left blank Customer details should not be left blank Checkin &checkout date should match with the system date Room details Customer details constraints

ROOM BOOKING
Checkin Checkout datebase input output Room will be booked

Room details

booking table

18

CAB BOOKING
Customer name should be match with room booking table Cab booking date should be matched Contact no. should be numeric and not be more than 10 digit Customer name Date of issuing cab Contact no. Room no. Type of cab Room booking database Cab table input constraints

CAB BOOKING

output

cab will booked

CONFERENCE HALL
Customer details should not be left blank Room details should not be left blank Reason for booking must be mentioned Time limit should not be exceed more than 5 hours Customer details Room details Purpose Capacity charges for booking date of booking time limit input constraints

CONFERENCE HALL
database hall table

output

conference hall will be booked

19

FACILITY FACILITY

SWIMMING POOL

SWIMMING POOL
Customer details should not be left blank Age below 14 should allowed in the children swimming pool Age above 14 should allowed in the adult swimming pool

Customer details Room no. Age input

constraints

SWIMMING POOL
Database Swimming table

output

20

BILL

Customer details should not be left blank Room details should not be left blank If facility is used charges must be calculated

Customer details Room details Chekin date Checkout date Facility input

constraints

BILL

output

bill will be generated

database bill table

21

DATA FLOW DIAGRAMS


Data flows are data structures in motion, while data stores are data structures. Data flows are paths or pipe lines, along which data structures travel, where as the data stores are place where data structures are kept until needed. Data flows are data structures in motion, while data stores are data structures at rest. Hence it is possible that the data flow and the data store would be made up of the same data structure. Data flow diagrams is a very handy tool for the system analyst because it gives the analyst the overall picture of the system, it is a diagrammatic approach. A DFD is a pictorial representation of the path which data takes From its initial interaction with the existing system until it completes any interaction. The diagram will describe the logical data flows dealing the movements of any physical items. The DFD also gives the insight into the data that is used in the system i.e., who actually uses it is temporarily stored. A DFD does not show a sequence of steps. A DFD only shows what the different process in a system is and what data flows between them. The following are some DFD symbols used in the project External entities Process: A transaction of information that resides within the bounds of the system to be module.

DATASTORE: A repository of data that is to be stored for use by one or more processes, may be as simple as buffer of queue or as a relational database.

22

ER DIAGRAM OF HOTEL MANAGEMENT SYSTEM

23

CHAPTER 4
SNAPSHOT

24

4. SNAPSHOT
LOGIN FORM

25

26

27

28

29

30

31

32

33

34

CODING 5

35

5. CODING:
LOGIN FORM
Option Explicit Dim con As ADODB.Connection Dim rs As ADODB.Recordset Private Sub file_Click() Option Explicit Private Sub cmdCancel_Click() End Sub Private Sub cmdOK_Click() Else MsgBox "Invalid Password, try again!", , "PCI Login" SendKeys "{Home}+{End}" End If End Sub End Sub Private Sub Image1_Click() Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from Login" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic Dim chkPassword While Not rs.EOF 36

If Text1 = rs.Fields("username") And Text2 = rs.Fields("password") Then chkPassword = "password" rs.MoveNext Wend If chkPassword = "password" Then Call MDIForm1.Show Unload Me con.Close Else MsgBox "Invalid Password, try again!", , "PCI Login" SendKeys "{Home}+{End}" End If End Sub Private Sub Image2_Click() Unload Me End Sub Private Sub Label1_Click() End Sub

MDI FORM
Private Sub bill_Click() Form6.Show End Sub Private Sub cabbooking_Click() Form5.Show End Sub Private Sub conferencehallbooking_Click() Form7.Show 37

End Sub Private Sub MDIForm_Load() MDIForm1.Show Me.Height = 7920 Me.Width = 12915 End Sub Private Sub roombooking_Click() Form4.Show End Sub Private Sub customerdetails_Click() Form3.Show End Sub Private Sub changepassword_Click() form2.Show End Sub Private Sub exit_Click() Unload Me End Sub Private Sub new_Click() New1.Show End Sub Private Sub roomentry_Click() Form1.Show End Sub Private Sub swimmingpoolfacility_Click() Form8.Show End Sub

38

CHANGE PASSWORD
Option Explicit Dim con1 As ADODB.Connection Dim rs As ADODB.Recordset Private Sub Command6_Click() Set con1 = CreateObject("Adodb.connection") con1.Provider = "Microsoft.jet.oledb.4.0" con1.Open App.Path & "\db3.mdb" Dim strsql As String Dim users As String users = Text1.Text strsql = "Select * from Login where username='" & users & "'" Set rs = New ADODB.Recordset rs.Open strsql, con1, adOpenForwardOnly, adLockOptimistic If Text3.Text <> Text4.Text Then MsgBox ("Password do not match!"): Exit Sub If rs.EOF = False Then If rs.Fields("password") = Text2.Text Then rs.Fields("password") = Text4.Text rs.Update Else MsgBox ("Old Password do not match!") Exit Sub End If MsgBox ("Password successfully change!!!") rs.Close Private Sub Command2_Click() Unload Me 39

End Sub Private Sub Label1_Click() End Sub

ROOM DETAILS
Private Sub Command1_Click() Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from Room" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox(" rs.AddNew If Not rs.EOF Then rs.Fields("Room number") = Text1.Text rs.Fields("Room type") = Text2.Text rs.Fields("Room capacity") = Text3.Text rs.Fields("Room status") = Text4.Text rs.Fields("Check in date") = Text5.Text rs.Fields("Check out date") = Text6.Text rs.Update MsgBox ("Room entry Successfully!!!!") Private Sub Form_Load() Me.Height = 9285 Me.Width = 15360 Are you sure(Y/N)???", 4) = 7 Then Exit Sub

40

End Sub Private Sub Label2_Click() Me.Height8730 Me.Width8025 End Sub Private Sub Command2_Click() Unload Me End If End Sub

CUSTOMER DETAILS
Private Sub Command1_Click() Form3.Show Dim con As ADODB.Connection Dim rs As ADODB.Recordset Dim a, b, c, e As Integer Dim d As String Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from Cust" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox(" rs.AddNew If Not rs.EOF Then Are you sure(Y/N)???", 4) = 7 Then Exit Sub

41

rs.Fields("customer name") = Text1.Text rs.Fields("customer_id") = Text2.Text rs.Fields("fathers name") = Text3.Text rs.Fields("dob") = Text4.Text rs.Fields("contact") = Text5.Text rs.Fields("address") = Text6.Text rs.Fields("gender") = Text7.Text rs.Update MsgBox ("Add Customer Details Successfully!!!!") Call MDIForm1.Show Unload Me End If End Sub

ROOM BOOKING
Private Sub Command1_Click() Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from book" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox(" rs.AddNew If Not rs.EOF Then rs.Fields("Customer name") = Text1.Text Are you sure(Y/N)???", 4) = 7 Then Exit Sub

42

rs.Fields("Customer_id") = Text2.Text rs.Fields("Room number") = Text3.Text rs.Fields("Room type") = Text4.Text rs.Fields("Contact number") = Text5.Text rs.Fields("Checkin date") = Text6.Text rs.Fields("Checkout date") = Text7.Text rs.Update MsgBox ("Room Book Successfully!!!!") End If End Sub Private Sub Form_Load() Me.Height = 9285 Me.Width = 15360 End Sub Private Sub Label2_Click() Me.Height8730 Me.Width8025 End Sub End Sub End Sub Private Sub Command2_Click() Unload Me End If End Sub

43

CAB BOOKING
Private Sub Command1_Click() Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from cab" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox(" rs.AddNew If Not rs.EOF Then rs.Fields("customer name") = Text1.Text rs.Fields("customer_id") = Text2.Text rs.Fields("contact number") = Text3.Text rs.Fields("cab type") = Text4.Text rs.Fields("number of days") = Text5.Text rs.Fields("purpose") = Text6.Text rs.Update MsgBox ("Cab Book Successfully!!!!") End If End Sub Private Sub Command2_Click() Unload Me End Sub Private Sub Label1_Click() Form5.Show Are you sure(Y/N)???", 4) = 7 Then Exit Sub

44

End Sub

CONFERENCE HALL
Private Sub Command1_Click() Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from hall" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox(" rs.AddNew If Not rs.EOF Then rs.Fields("customer_id") = Text1.Text rs.Fields("contact number") = Text2.Text rs.Fields("time duration") = Text3.Text rs.Fields("purpose") = Text4.Text rs.Update MsgBox ("Conference hall Book Successfully!!!!") End If End Sub Private Sub Command2_Click() Unload Me End Sub Private Sub Label1_Click() Form7.Show End Sub 45 Are you sure(Y/N)???", 4) = 7 Then Exit Sub

BILL GENERATE
Private Sub Command1_Click() Dim con As ADODB.Connection Dim rs As ADODB.Recordset Dim a, b, c, e As Integer Dim d As String Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from bill" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox( Are you sure(Y/N)???", 4) = 7 Then Exit Sub rs.AddNew If Not rs.EOF Then rs.Fields("customer_id") = Text1.Text rs.Fields("contact number") = Text2.Text rs.Fields("type of room") = Text3.Text rs.Fields("number of days") = Text4.Text rs.Fields("other services") = Text5.Text rs.Update a = Val(Text4.Text) If Text3.Text = "ac" Then b = 2000 Else b = 1000

46

End If c = Val(Text5.Text) d = (a * b) + c Text6.Text = d End If rs.Fields("bill") = Text6.Text rs.Update MsgBox ("Add Generate bill Successfully!!!!") End Sub Private Sub Command2_Click() Unload Me End Sub Private Sub Label1_Click() Form6.Show End Sub

SWIMMING POOL
Private Sub Command1_Click() Set con = CreateObject("Adodb.connection") con.Provider = "Microsoft.jet.oledb.4.0" con.Open App.Path & "\db3.mdb" Dim strsql As String strsql = "Select * from swimming" Set rs = New ADODB.Recordset rs.Open strsql, con, adOpenForwardOnly, adLockOptimistic If MsgBox(" Are you sure(Y/N)???", 4) = 7 Then Exit Sub rs.AddNew

47

If Not rs.EOF Then rs.Fields("customer_id") = Text1.Text rs.Fields("customer name") = Text2.Text rs.Fields("room number") = Text3.Text rs.Fields("contact number") = Text4.Text rs.Fields("timing") = Text5.Text rs.Update MsgBox ("Swimming pool Book Successfully!!!!") End If End Sub Private Sub Command2_Click() Unload Me End Sub Private Sub Command3_Click() Unload Me End Sub Private Sub Label1_Click() Form8.Show Me.Height = 7365 Me.Width = 8010 End Sub

48

CHAPTER 6

49

6. CONCLUSION:

This project have been designed in a great user friendliness and largely providing attribute interface, the project is working with quick response and same level of security is also maintained. The database with MS-Access is maintained and frontend with VB given project has been developed in a group which helped us with different logic and ideas.

50