Project Helpine Report BANQUET HALL BOOKING

Similar documents
* To change this license header, choose License Headers in Project Properties.

Answer on question #61311, Programming & Computer Science / Java

/** Creates new form NewJFrame */ public NewJFrame() { initcomponents(); initblogsearch(); //initializes Index List box }

Appendix I: Software Coding

Design. Introduction

Java Programming Summer 2008 LAB. Thursday 8/21/2008

SUGGESTED SOLUTION IPCC MAY 2017EXAM. Test Code - I M J

1. i. What are the 3 major components of a information system and show their relationship input output

* To change this license header, choose License Headers in Project Properties.

Siebel Project and Resource Management Administration Guide. Siebel Innovation Pack 2013 Version 8.1/8.2 September 2013

Travel Agency. Khateeb Engineering Classes. Mini Project. Khateeb Engineering Classes: / Technology to be used

Practical Database Design Methodology and Use of UML Diagrams Design & Analysis of Database Systems

Human Error Taxonomy

Chapter 10. Database System Development Lifecycle

STRUCTURED SYSTEM ANALYSIS AND DESIGN. System Concept and Environment

ONLINE BILLBOARD VIKRAM KUMAR KONDAPANENI B.TECH, ACHARYA NAGARJUNA UNIVERSITY, 2007 A REPORT

Baluja Labs. REPORT On. Submitted in partial fulfillment of the requirements for qualifying UNDER SUPERVISON OF SUBMITTED BY: NAME: Enrolment No:

Chapter 8. Java continued. CS Hugh Anderson s notes. Page number: 264 ALERT. MCQ test next week. This time. This place.

Java continued. Chapter 8 ALERT ALERT. Last week. MCQ test next week. This time. This place. Closed book. Assignment #2 is for groups of 3

SCHOOL MANAGEMENT SYSTEM

Database Environment. Pearson Education 2009

Chapter System Analysis and Design. 5.1 Introduction

Transformation of analysis model to design model

Architectural Design. Architectural Design. Software Architecture. Architectural Models

Introduction to User Stories. CSCI 5828: Foundations of Software Engineering Lecture 05 09/09/2014

Product Documentation. ER/Studio Portal. User Guide. Version Published February 21, 2012

Chapter 2 Operating-System Structures

2 The IBM Data Governance Unified Process

System development, design & implementation

Software Engineering - I

Meltem Özturan misprivate.boun.edu.tr/ozturan/mis515

Middle East Technical University. Department of Computer Engineering

sqamethods Approach to Building Testing Automation Systems

ER/Studio Enterprise Portal User Guide

Requirement Analysis

WINDEV 23 - WEBDEV 23 - WINDEV Mobile 23 Documentation version

DOWNLOAD PDF TELEPHONE BILLING SYSTEM PROJECT

TERMINOLOGY MANAGEMENT DURING TRANSLATION PROJECTS: PROFESSIONAL TESTIMONY

Sample Exam. Advanced Test Automation - Engineer

ASTQB Advance Test Analyst Sample Exam Answer Key and Rationale



Chapter 2: The Database Development Process

Cyberthink Ecommerce Shopping Cart

QM Chapter 1 Database Fundamentals Version 10 th Ed. Prepared by Dr Kamel Rouibah / Dept QM & IS

ASG WHITE PAPER DATA INTELLIGENCE. ASG s Enterprise Data Intelligence Solutions: Data Lineage Diving Deeper

Chapter 1: The Database Environment

BIS Database Management Systems.

MIS Database Systems.

Up and Running Software The Development Process

Building a website. Should you build your own website?

Media Services Online Mohammed Abukhiran. Report 13 on the work of Week 13

UNIT II Requirements Analysis and Specification & Software Design

PROJECT ON ONLINE EXAM

Oracle Banking Digital Experience

Data warehouse architecture consists of the following interconnected layers:

Chapter 13. Application Architecture and Modeling. McGraw-Hill/Irwin. Copyright 2007 by The McGraw-Hill Companies, Inc. All rights reserved.

Microsoft SharePoint Server 2013 Plan, Configure & Manage

SOFTWARE ENGINEERING : A MCQ BOOK CODE : RBMCQ0602. Second Edition

Darshan Institute of Engineering & Technology for Diploma Studies

CYBERCRIME AS A NEW FORM OF CONTEMPORARY CRIME

ER/Studio Enterprise Portal User Guide

CS3205: Task Analysis and Techniques

QA Best Practices: A training that cultivates skills for delivering quality systems

Requirement Engineering within an Agile Environment BY KEJI GIWA. Digital Bananas Technology

DESIGN TIME PRO. RGSR Software Inc. Design Time Pro Support Guide

DEPARTMENT OF COMPUTER SCIENCE AND ENGINEERING CS SOFTWARE ENGINEERING

Sparta Systems TrackWise Digital Solution

Software Design Description Report

(C) Global Journal of Engineering Science and Research Management

Moving from a Paper to Paperless validation effort and how to get the most efficient mix of Manual vs. Automated testing.

Chapter 9. Software Testing

CHAPTER 6 DATABASE MANAGEMENT SYSTEMS

XP: Planning, coding and testing. Planning. Release planning. Release Planning. User stories. Release planning Step 1.

Electronic Grants Administration & Management System - EGrAMS

Out for Shopping-Understanding Linear Data Structures English

Analytics: Server Architect (Siebel 7.7)

Chandni Soneji Kinjal Tada

Practical Introduction to SharePoint 2007

Housing Estates Information Management System Based on.net. Jianliang Min

Ebook : Overview of application development. All code from the application series books listed at:

The ITIL v.3. Foundation Examination

The Development of Critical Undergraduate Program Selection System (CUPSS) for Admission to Malaysian Public Universities

Administrator s Guide

FORMALIZED SOFTWARE DEVELOPMENT IN AN INDUSTRIAL ENVIRONMENT

OPERATING SYSTEMS. Prescribed Text Book Operating System Principles, Seventh Edition By Abraham Silberschatz, Peter Baer Galvin and Greg Gagne

Embarcadero PowerSQL 1.1 Evaluation Guide. Published: July 14, 2008

FROM A RELATIONAL TO A MULTI-DIMENSIONAL DATA BASE

Oracle. Engagement Cloud Using Service Request Management. Release 12

EMC GREENPLUM MANAGEMENT ENABLED BY AGINITY WORKBENCH

LESSON 13: LANGUAGE TRANSLATION

XP: Planning, coding and testing. Practice Planning game. Release Planning. User stories. Annika Silvervarg

Use these instructions to update the release version of Premium Edition 2011 (Build ).

Business Analysis for Practitioners - Requirements Elicitation and Analysis (Domain 3)

International School of Informatics and management, Jaipur Billing System Synopsis TEAM GROUP - 04 TEAM MEMBERS -ANIL KUMAR ANJANA -BHAIYA LAL ANJANA

Getting Started in CAMS Enterprise

CS 231 Data Structures and Algorithms, Fall 2016

DefendX Software Control-Audit for Hitachi Installation Guide

Database Systems: Design, Implementation, and Management Tenth Edition. Chapter 9 Database Design

Lecture 8 Requirements Engineering

Transcription:

Project Helpine Report BANQUET HALL BOOKING - 1 -

BANQUET HALL BOOKING TABLE OF CONTENT Contents Page No. Acknowledgment 3 Declaration 4 1. Introduction & Objectives of the Project 1.1 Introduction 7 1.2 Objectives of the Project 8 1.3 Project Category 9 1.4 Drawback of Current Manual-System 10 1.5 Proposed System 11 1.6 Existing System And need For System 12 1.7 Input and output of the project 13 2. System Study 2.1 Preliminary Investigation 19 2.2 System Development Life Cycle 20 2.3 Feasibility Study 25 2.4 Economic Feasibility 26 2.5 Technical Feasibility 28 3. System Analysis 3.1 Importance of Computerized System 30 3.2 Principle of System Analysis 31 4. System Design 4.1 System Design 33 4.2 Data Modeling 36-2 -

4.3 E-R Diagram 38 4.4 Context Level DFD 39 4.5 Modules 45 4.6 Process Logic for Each Modules 47 4.7 Tool/Platform, Hardware and Software Requirement Specification 48 4.8 Scheduling 49 5. System Development 5.1 Source Code 52 5.2 Code Efficiency 122 6. Testing 6.1 Testing Phase 124 6.2 Level of Testing 125 6.3 Verification and Validation (V&V) 130 6.4 Test Cases 131 7. System Implementation 7.1 Post Implementation Maintenance and Review 136 7.2 Hardware Evaluation Factors 136 7.3 Software Evaluation Factors 138 7.4 Conversion and Training 139 7.5 Training Needs 140 8. Cost Estimation of the Project 141 9. GANTT & PERT CHART 142 10. Security and Validations Checks 145 11. Scope of Future Application 146 12. Conclusion 147 13. Bibliography 148-3 -

14. Glossary 149-4 -

1.1 INTRODUCTION Banquet Hall Booking System is a Window based project which act as a bridge between potential Banquet users and Banquet owners. Banquet booking system provides complete listing of banquets in different districts, where each district is further having different sectors, which may comprise of around 100 families. Each sector is having two banquet halls, one is around 5000 sq. meter and another is 2000 sq.m. These halls can be booked by the family head person residing in that sector. This project is designed to provide comprehensive mechanism of Banquet hall booking for general users. We have complete listing of Banquets in different districts. The users just need to register the themselves. The users can search and book the Banquet for their choice of date. It deals with the operations of Banquet booking, how exactly the system works and who are all involved in the system. General users can get information about banquets, cancellation, status of booking etc, Administrator is an authorized user he can: Add District Details. Add Sector Details. Updating Booking Status. Adding member Details. Report generation. - 5 -

1.2 OBJECTIVES OF THE SYSTEM The objective of this development effort is:- To provide the information regarding Banquets. To provide the information about the Booking of users choice. To provide the functionality of Booking and Cancellation. To provide the information of status of catering, facilities available. To provide the facility to maintain the records of users. Information can be easily accessed. This system will save the time of the Users. PURPOSE Banquet Hall Booking a Management system with Automation System this project is aimed at automation of a banquet hall booking and thus to develop customize software package for Banquet halls. - 6 -

1.3 PROJECT CATEGORY This project is basically categorized as RDBMS. The project is based on three tier architecture. The three tier architecture where the application is divided into three logical constituents. Presentation layer In this layer mainly following pages contained: 0. Web Pages 1. User Control 2. Master Pages Business Layer Business Logic, 0. Result Engine 1. User permissions logic 2. Access Rights Data Layer Provide handling and validation of data (MS SQL Server in this case). 0. Sql 1. Sybase 2. Oracle 3. Access - 7 -

1.4 DRAWBACKS OF CURRENT MANUAL- SYSTEM The current manual system has a lot of paper work and it does not deal with exact details. With the increase in database, it will become a massive job to maintain the database. Requires large quantities of file cabinets, which are huge and require quite a bit of space in the office, which can be used for storing records of previous claims. The retrieval of records of employees will be a tedious job. Lack of security for the records, anyone disarrange the records of your system. ESTABLISH THE NEED OF NEW SYSTEM 1. Problem of Reliability: Current system is not reliable. It seems to vary in quality from one month to the next. Some times it gives good output, but some times the output is worst. 2. Problem of Accuracy: There are too many mistakes in reports. 3. Problem of timeliness: In the current system the reports and output produced is mostly late and in most of the cases it is useless because it is not on time. 4. Problem of Validity: The output and reports mostly contains misleading information. The customer's information is sometimes not valid. 5. Problem of Economy: The current system is very costly. We have to spend lots of money to keep the system up and going, but still not get the desired results. 6. Problem of Capacity: The current system is suffering from problem of capacity also. The staff for organization is very less and the workload is too much. Few peoples cannot handle all the work. - 8 -

1.5 PROPOSED SYSTEM 1. Details: The new proposed system stores and maintains all the store details, customers details, rates details etc. 2. Calculations: The new proposed system updates tables and other information automatically and it is very fast and accurate. 3. Registers: There is no need of keeping and maintaining database and information manually. It remembers each and every record and we can get any report at any time. 4. Speed: The new proposed system is very fast with 100% accuracy and saves time. 5. Manpower: The new proposed system needs less manpower. Less people can do the large work. 6. Efficiency: The new proposed systems complete the work of many people in less time. 7. Reduces redundancy: The most important benefit of this system is that it reduces the redundancy of data within the data. 8. Work load: Reduces the work load of the data store by helping in easy updates of the products and providing them with the necessary details together with financial transactions management. 9. Easy statements: Month-end and day-end statement easily taken out without getting headaches on browsing through the day end statements. - 9 -

1.6 EXISTING SYSTEM AND NEED FOR SYSTEM The existing system is manual /machine systems where the users must have to perform their manually. It will take more time and this whole procedure is very tedious and takes a lot of time. Problems of the existing system It is limited to a single system. It has lot of manual work (Manual work does not mean working with pen or paper, rather includes working on spread sheets and other simple software.) The present system is very less secure. It unable to generate different kinds of reports. It is difficult to maintain phone bookings and cancellations. Does not provide global support. User cannot do the reservation from remote place. Retrieval of information is difficult and time consuming. A lot of time and manual effort is required - 10 -

1.7 INPUT AND OUTPUT OF THE PROJECT Input To the Project Login Module: This is very first module. This module contains authentication like user ID and Password New User s Details: New users details are added by the users. If users enter their valid details, existed user can then add booking details Booking Module: Booking details are added by the users. Feedbacks: Feedbacks can be given by the users. Queries: Users can enquire about the services provided by the Banquets. Output of the Project Administrator can give Availability of the banquet Respond users queries Respond user s feedbacks Report generate are I. Feedback details II. III. IV. Booking details Banquet details Users details - 11 -

SOFTWARE & HARDWARE REQUIREMENTS The need of today s software development is competence in a GUI based front-end tool, which can connect to Relational Database engines. This gives the programmer the opportunity to develop client server based commercial applications. FRONT END a) Java (Front End) Java has the following properties: Platform independent: Java programs use the Java virtual machine as abstraction and do not access the operating system directly. This makes Java programs highly portable. A Java program (which is standard complaint and follows certain rules) can run unmodified on all supported platforms, e.g. Windows or Linux. Object-orientated programming language: Except the primitive data types, all elements in Java are objects. Strongly-typed programming language: Java is strongly-typed, e.g. the types of the used variables must be pre-defined and conversion to other objects is relatively strict, e.g. must be done in most cases by the programmer. Interpreted and compiled language: Java source code is transferred into the bytecode format which does not depend on the target platform. These bytecode instructions will be interpreted by the Java Virtual machine (JVM). The JVM contains a so called Hotspot-Compiler which translates performance critical bytecode instructions into native code instructions. Automatic memory management: Java manages the memory allocation and deallocation for creating new objects. The program does not have direct access to the memory. The so-called garbage collector deletes automatically objects to which no active pointer exists. The Java syntax is similar to C++. Java is case sensitive, e.g. variables called myvalue and myvalueare treated as different variables. - 12 -

BACK END:-My Sql My SQL is an application used to create computer databases for the Microsoft Windows family of server operating systems. It provides an environment used to generate databases that can be accessed from workstations, the web, or other media such as a personal digital assistant (PDA). MY SQL is probably the most accessible and the most documented enterprise database environment right now. This also means that you can learn it a little quicker than most other database environments on the market To start, you must have a computer that runs an appropriate operating system like Microsoft Windows >= XP Home Edition: that includes Windows XP Home Edition, Windows XP Professional, Windows 2000 Professional, or any version of Windows Server 2003. In this case, you must install MY SQL Yog. What is SQL Used for: Using SQL one can create and maintain data manipulation objects such as table, views, sequence etc. These data manipulation objects will be created and stored on the server's hard disk drive, in a tablespace, to which the user has been assigned. - 13 -

Once these data manipulation objects are created, they are used extensively in commercial applications. DML, DCL, DDL: In addition to the creation of data manipulation objects, the actual manipulation of data within these objects is done using SQL. The SQL sentences that are used to create these objects are called DDL's or Data Definition Language. The SQL sentences used to manipulate data within these objects are called DML's or Data Manipulation Language. The SQL sentences, which are used to control the behavior of these objects, are called DCL's or Data Control Language. - 14 -

- 15 -

2.1 PRELIMINARY INVESTIGATION System development, a process consisting of two major steps of system analysis and design, start when management or sometimes system development personnel feel that a new system or an improvement in the existing system is required. The system development life cycle is classically thought of as the set of activities that analysts, designers and users carry out to develop and implement an information system. The system development life cycle consists of the following activities: Preliminary investigation Determination of system requirements Design of system Development of software System testing Implementation, evaluation, and maintenance A request to take assistance from information system can be made for many reasons, but in each case someone in the organization initiates the request is made, the first system activity the preliminary investigation begins. This activity has three parts: 1) Request clarification 2) Feasibility study 3) Request approval Request clarification: Many requests from employees and users in the organizations are not clearly defined, therefore it becomes necessary that project request must be examined and clarified properly before considering systems investigation. - 16 -

2.2 SYSTEM DEVELOPMENT LIFE CYCLE Systems are created to solve problems. One can think of the systems approach as an organized way of dealing with a problem. In this dynamic world, the subject System Analysis and Design (SAD), mainly deals with the software development activities. DEFINING A SYSTEM:- A collection of components that work together to realize some objective forms a system. Basically there are three major components in every system, namely input, processing and output. In a system the different components are connected with each other and they are interdependent. For example, human body represents a complete natural system. We are also bound by many national systems such as political system, economic system, educational system and so forth. The objective of the system demands that some output is produced as a result of processing the suitable inputs. SYSTEM LIFE CYCLE:- System life cycle is an organizational process of developing and maintaining systems. It helps in establishing a system project plan, because it gives overall list of processes and sub-processes required for developing a system. System development life cycle means combination of various activities. In other words we can say that various activities put together are referred as system development life cycle. In the System Analysis and Design terminology, the system development life cycle means software development life cycle. - 17 -

Following are the different phases of software development cycle: System study Feasibility study System analysis System design Coding Testing Implementation Maintenance - 18 -

The Different Phases Of Software Development Life Cycle Are Shown Below. FIG: SHOWING GENERAL LIFE CYCLE PROCESS AND PERCENTAGE OF TIME DEVOTED - 19 -

A system analysis is a separation of a substance into parts for study and their implementation and detailed examination. Before designing any system it is important that the nature of the business and the way it currently operates are clearly understood. The detailed examination provides the specific data required during designing in order to ensure that all the client's requirements are fulfilled. The investigation or the study conducted during the analysis phase is largely based on the feasibility study. Rather it would not be wrong to say that the analysis and feasibility phases overlap. High-level analysis begins during the feasibility study. Though analysis is represented as one phase of the system development life cycle (SDLC), this is not true. Analysis begins with system initialization and continues until its maintenance. Even after successful implementation of the system, analysis may play its role for periodic maintenance and up gradation of the system. One of the main causes of project failures is inadequate understanding, and one of the main causes of inadequate understanding of the requirements is the poor planning of system analysis. Analysis requires us to recall the objectives of the project and consider following three questions: What type of information is required? What are the constraints on the investigation? What are the potential problems that may make the task more difficult? Keeping the above questions in mind and considering the survey conducted to determine the need of the system, the total system was deigned and can be described as under: - 20 -

The three major parts of the system are: Providing Information: The system is effectively used to provide large variety of information to the interested customer. The major purpose of the site is to easily provide access to records of various automobile such as car with quick update to latest modifications in the records. This thing is not at all possible in printed material, which are updated only once a few weeks. It also gives information about the general usage of the system for first time visitors. The system itself works as a information provider for automobile organization. - 21 -

2.3 FEASIBILITY STUDY The feasibility study proposes one or more conceptual solution to the problem set of the project. In fact, it is an evaluation of whether it is worthwhile to proceed with project or not. Feasibility analysis usually considers a number of project alternatives, one that is chosen as the most satisfactory solution. These alternatives also need to be evaluated in a broad way without committing too many resources. Various steps involved in feasibility analysis are: 1. To propose a set of solution that can realize the project goal. These solutions are usually descriptions of what the new system should look like. 2. Evaluation of feasibility of such solutions. Such evaluation often indicates shortcomings in the initial goals. This step is repeated as the goals are adjusted and the alternative solutions are evaluated. Steps in feasibility Analysis are: 1. Identify deficiency by pinpointing, missing functions, unsatisfactory performance, Excessive cost of operations. 2. Set goals to remove these deficiencies. 3. Goals must be quantified, realizable within the constraints of an organization, broken down into sub goals agreeable to all concerned. 4. Set goals not only to remove deficiencies but also to effectively meet competition. For instance, goals must be based on what competitors do. - 22 -

2.4 ECONOMIC FEASIBILITY Economic analysis is the most frequently used technique for evaluating the effectiveness of a proposed system. More commonly known as cost / benefit analysis; in this procedure we determine the benefits and savings that are expected from a proposed system and compare them with costs. We found the benefits outweigh the costs; we take a decision to design and implement the new proposed system. During the feasibility phase, broad alternatives solutions are examined. For each alternate solution the cost and benefits have to be examined before designing one of the alternatives. Broad solutions will consist of: 1. Specifications of information to be made available by the system. 2. Description of what will be done manually and what the computer will do. 3. Specification of new computing equipment needed or specification of expansion of an existing computer. COST AND BENEFIT ANALYSIS Developing an IT application is an investment. Since after developing that application it provides the organization with profits. Profits can be monetary or in the form of an improved working environment. However, it carries risks, because in some cases an estimate can be wrong. And the project might not actually turn out to be beneficial. Cost benefit analysis helps to give management a picture of the cost, benefits and risks. It usually involves comparing alternate investments. Cost benefit determines the benefits and savings that are expected from the system and compares them with the expected costs. In performing cost and benefit analysis it is important to identify cost and benefits factors. Cost and benefits can be categorized into the following categories: - 23 -

1. Development Costs Development costs is the costs that are incurred during the development of the system. It is one time investment. 2. Operating Costs Operating Costs are the expenses required for the day to day running of the system. Examples of Operating Costs are Wages, Supplies and Overheads. 3. Hardware/Software Costs It includes the cost of purchasing or leasing of computers and it s peripherals. Software costs involves required S/W costs. 4. Personnel Costs It is the money spent on the people involved in the development of the system. 5. Facility Costs Expenses that are incurred during the preparation of the physical site where the system will be operational. These can be wiring, flooring, acoustics, lightning, and air-conditioning. 6. Supply Costs These are variable costs that are very proportionately with the amount of use of paper, ribbons, disks, and the like. BENEFITS We can define benefits as Profit or Benefit = Income Costs Benefits can be accrued by: Increasing income, or Decreasing costs, or Both - 24 -

2.5 TECHNICAL FEASIBILITY Today, very little is technically impossible. Consequently, technical feasibility looks at what is practical and reasonable. Technical feasibility addresses three major issues: 1. Is the proposed technology or solution practical? 2. Do we currently possess the necessary technology? 3. Do we possess the necessary technical expertise, and is the schedule reasonable? Is the Proposed Technology or Solution Practical? The technology for any defined solution is normally available. The question whether that technology is mature enough to be easily applied to our problems. Some firms like to use state-of-the-are technology, but most firms prefer to use mature and proven technology. A mature technology has a larger customer base for obtaining advice concerning problems and improvements. Do We Currently Possess the Necessary Technology? Assuming the solution's required technology is practical, we must next ask ourselves, is the technology available in our information systems shop? If the technology is available, we must ask if we have the capacity. For instance, will our current printer be able to handle the new reports and forms required of a new system? If the answer to any of these questions is no, then we must ask ourselves, Can we get this technology? The technology may be practical and available, and, yes, we need it. But we simply may not be able to afford it at this time. Although this argument borders on economic feasibility, it is truly technical feasibility. If we can't afford the technology, then the alternative that requires the technology is not practical and is technically infeasible! - 25 -

- 26 -

3.1 IMPORTANCE OF COMPUTERIZED BANQUET HALL BOOKING There are several attributes in which the computer based information works. Broadly the working of computer system is divided into two main groups: Transaction System Decision Support System Transaction System: A transaction is a record of some well-defined single and usually small occurrence in a system. Transactions are input into the computer to update the database files. It checks the entering data for its accuracy. This means that numeric data appears in numeric field and character data in character field. Once all the checks are made, transaction is used to update the database. Transaction can be inputted in on-line mode or batch mode. In on-line mode, transactions are entered and updated into the database almost instantaneously. In batch mode, transactions are collected into batches, which may be held for a while and inputted later. Decision Support System: It assists the user to make analytical decision. It shows the various data in organized way called analysis. This analysis can be made to syrdy preferences and help in making decisions. Computer system works out best with record maintenance. It will tell you which customer would get how much pending/reports statements. It will also help to search the information about a particular person by simply entering his telephone number. User can store information as per requirement, which can be used for comparison with other reports. - 27 -

3.2 PRINCIPLES OF SYSTEM ANALYSIS Principles: 1. Understand the problem before you begin to create the analysis model. 2. Develop prototypes that enable a user to understand how human machine interaction will occur. 3. Record the origin of and the reason for every requirement. 4. Use multiple views of requirements like building data, function and behavioral models. 5. Work to eliminate ambiguity. A Complete Structure: The limited time and resources have restricted us to incorporate, in this project, only the main activities that are performed in news sites, but utmost care has been taken to make the system efficient and user friendly. For the optimum use of practical time it is necessary that every session is planned. Planning of this project will include the following things: Topic Understanding. Modular Break Up of the System. Processor Logic for Each Module. Database Requirements. Topic Understanding: It is vital that the field of application as introduced in the project may be totally a new field. So as soon as the project was allocated to me, I carefully went through the project to identify the requirements of the project. Modular Break Up of the System: Identify The Various Modules In The System. List Them In The Right Hierarchy. Identify Their Priority Of Development Description Of The Modules: - 28 -

- 29 -

4.1 SYSTEM DESIGN The design document that we will develop during this phase is the blueprint of the software. It describes how the solution to the customer problem is to be built. Since solution to complex problems isn t usually found in the first try, iterations are most likely required. This is true for software design as well. For this reason, any design strategy, design method, or design language must be flexible and must easily accommodate changes due to iterations in the design. Any technique or design needs to support and guide the partitioning process in such a way that the resulting sub-problems are as independent as possible from each other and can be combined easily for the solution to the overall problem. Sub-problem independence and easy combination of their solutions reduces the complexity of the problem. This is the objective of the partitioning process. Partitioning or decomposition during design involves three types of decisions: - Define the boundaries along which to break; Determine into how money pieces to break; and Identify the proper level of detail when design should stop and implementation should start. Basic design principles that enable the software engineer to navigate the design process suggest a set of principles for software design, which have been adapted and extended in the following list: Free from the suffer from "tunnel vision." A good designer should consider alternative approaches, judging each based on the requirements of the problem, the resources available to do the job. The design should be traceable to the analysis model. Because a single element of the design model often traces to multiple requirements, it is necessary to have a means for tracking how requirements have been satisfied by the design model. The design should not repeat the same thing. Systems are constructed using a set of design patterns, many of which have likely been encountered before. These patterns should always be chosen as an alternative to reinvention. Time is short and resources are - 30 -

limited! Design time should be invested in representing truly new ideas and integrating those patterns that already exist. The design should "minimize the intellectual distance" between the software and the problem as it exists in the real world. That is, the structure of the software design should (whenever possible) mimic the structure of the problem domain. The design should exhibit uniformity and integration. A design is uniform if it appears that one person developed the entire thing. Rules of style and format should be defined for a design team before design work begins. A design is integrated if care is taken in defining interfaces between design components. The design activity begins when the requirements document for the software to be developed is available. This may be the SRS for the complete system, as is the case if the waterfall model is being followed or the requirements for the next "iteration" if the iterative enhancement is being followed or the requirements for the prototype if the prototyping is being followed. While the requirements specification activity is entirely in the problem domain, design is the first step in moving from the problem domain toward the solution domain. Design is essentially the bridge between requirements specification and the final solution for satisfying the requirements. The design of a system is essentially a blueprint or a plan for a solution for the system. We consider a system to be a set of components with clearly defined behavior that interacts with each other in a fixed defined manner to produce some behavior or services for its environment. A component of a system can be considered a system, with its own components. In a software system, a component is a software module. The design process for software systems, often, has two levels. At the first level, the focus is on deciding which modules are needed for the system, the specifications of these modules, and how the modules should be interconnected. This is what is called the system design or top-level design. In the second level, the internal design of the modules, or how the specifications of the module can be satisfied, is decided. This design level is often called detailed design or logic design. Detailed design essentially expands the system - 31 -

design to contain a more detailed description of the processing logic and data structures so that the design is sufficiently complete for coding. Because the detailed design is an extension of system design, the system design controls the major structural characteristics of the system. The system design has a major impact on the testability and modifiability of a system, and it impacts its efficiency. Much of the design effort for designing software is spent creating the system design. The input to the design phase is the specifications for the system to be designed. Hence, reasonable entry criteria can be that the specifications are stable and have been approved, hoping that the approval mechanism will ensure that the specifications are complete, consistent, unambiguous, etc. The output of the top-level design phase is the architectural design or the system design for the software system to be built. This can be produced with or without using a design methodology. Reasonable exit criteria for the phase could be that the design has been verified against the input specifications and has been evaluated and approved for quality. A design can be object-oriented or function-oriented. In function-oriented design, the design consists of module definitions, with each module supporting a functional abstraction. In object-oriented design, the modules in the design represent data abstraction (these abstractions are discussed in more detail later). In the function-oriented methods for design and describe one particular methodology the structured design methodology in some detail. In a function- oriented design approach, a system is viewed as a transformation function, transforming the inputs to the desired outputs. The purpose of the design phase is to specify the components for this transformation function, so that each component is also a transformation function. Hence, the basic output of the system design phase, when a function oriented design approach is being followed, is the definition of all the major data structures in the system, all the major modules of the system, and how the modules interact with each other. Once the designer is satisfied with the design he has produced, the design is to be precisely specified in the form of a document. To specify the design, specification languages are used. Producing the design specification is the ultimate objective of the design phase. The purpose of this design document is quite different from that of the - 32 -

design notation. Whereas a design represented using the design notation is largely to be used by the designer, a design specification has to be so precise and complete that it can be used as a basis of further development by other programmers. Generally, design specification uses textual structures, with design notation helping in understanding 4.2 DATA MODELING Introduction to data dictionary: Data dictionaries are an integral component of structured analysis, since data flow diagrams by themselves do not fully describe the subject of the investigation. The data flow diagrams provide the additional details about the project/system. Data Dictionary (Definition): A data dictionary is a catalog- a repository- of the elements in a system. These elements center on the data and the way they are structured to meet user requirements and organization needs. A data dictionary consists of a list of all the elements composing the data flowing through a system. The major elements are data flows, data stores, and processes. The data dictionary stores details and descriptions of these elements. Admin_Login Table: To store admin login details Field Type Constraint Data Type Username Char (30) Not null Username Password Char(30) Not null Password Booking Table: To store Booking Details Field Type Constraint Data Type Member_id Varchar (30) Primary key Member Id Email_id Varchar (70) Not Null Email Id Date_of_book Date Not Null Date of Booking Venue Varchar (100) Not Null Venue Event Varchar (100) Not Null Event Timings Date Time Not Null Timings Contact_no Number (10) Not Null Contact No Queries Varchar (100) Not Null Queries - 33 -

Community_Hall Table: To store community Hall details Field Type Constraint Data Type CommHall_id Varchar (10) Primary Key Community Hall Id CommHall_Name Varchar (50) Not null Community Hall Name CommHall_address Varchar (50) Not Null Community Hall Address CommHall _city Varchar (50) Not Null Community Hall City CommHall_state Varchar (50) Not Null Community Hall State Contact_Person Varchar (50) Not Null Contact Person Contact No Number (10) Not Null Contact No Facilities Available Varchar (200) Not Null Facilities Available Member Login Table: To store Member Details Field Type Constraint Data Type Member_id Varchar (10) Not null Member ID Password Varchar (30) Not null Password Email Varchar (60) Not Null Email Id Booking Status Table Field Type Constraint Data Type Comm hall_id Varchar (10) Not null Community Hall Id Status Varchar (30) Not null Status Date_of_booking Varchar (60) Not Null Date of Booking Date_of_event Facilities_Available Table Field Type Constraint Data Type Faciliy_name Varchar (10) Not null Facility Facility_details Varchar (30) Not null Details cost Number Not Null Cost - 34 -

4.3 E-R DIAGRAM - 35 -

4.4. DATA FLOW DIAGRAM Context Level DFD for Banquet Hall Booking Admin Check Bookings Update Database Add Facilities Add Banquet Details Perform Bookings and Cancellations Banquet Hall Booking System Get Facilities and Cost Details Get Booking Details Member - 36 -

Ist Level DFD for Booking Module Customer Invoice 1.4 Generate Bill 1.3 Book the Banquet Accounts Member_id Email_id 1.1 Accept the Customer booking request Banquet Hall Booking System Banquet Booking Hall 1.2 Authenticate The Password Customer - 37 -

Ist Level DFD for Entering the Banquet ADMIN 2.1 Enter the Banquet Details Banquet Hall Booking System Banquet 2.2 Validate & Store in the Database - 38 -

Ist Level DFD For Cancellation Module Customer Invoice 3.3 Cancel the booking Accounts 3.1 Accept the Customer request from user Banquet Hall Booking System Cancellation 3.2 Check the Validate from Booking Table Booking - 39 -

Ist Level DFD for Booking Inquiries Form Customer Booking Status 4.3 Respond to the customer 4.1 Accept the Customer request Banquet Hall Booking System Banquet 4.2 Check the Database for the require Booking - 40 -

IInd Level DFD for Login Module USER 5.1 Accept the user Name & Password Screen Home Banquet Hall Booking System 5.2 Authenticate The Password Login Module - 41 -

4.5 MODULES i) Modules & Their Description The Banquet Hall Booking deals with the information System for Banquets Bookings. This project explains about the booking of banquet halls from a short event to a complete combination of activities, including meetings, conferences, exhibitions etc. This website helps any authorized person to book the halls from internet and also shows the availability of a particular hall at the chosen date and time. The project is divided into different modules. They are follows:- a) Administration: This module is divided into different sub-modules, they are:- Booking Banquets Districts, Sectors Services Reports Search b) Users: This module is specially for Customers:- Service Details (DJ, Lightning, Video Recording, Catering) Availability Booking Banquet Details: Once the user click on this module he/she will be able to know the Banquet details along with its mode of services, he also can know these best services by his past records. This will also inform the customer how flexible mode of booking/secured/punctual it is. Password: In this module, this website is for multiple users. If a User enters a password and the software checks its validity. If the password is valid then option is given to change the password, otherwise Invalid User/Password message is displayed. There is an option for password recovery, log out, login, new users sign in. The Administrator can also update changes in the site after login. - 42 -

Feedback: This module keeps track of all the feedbacks given by the users for future records. Reports: This module concerns with various report generation based on the Admin request. Following types of reports are generated- District Details Banquet Details Booking Status Members Details Feedback Reports Service Details: when the user clicks on this module he/she will be informed about the detailed services the Banquet has. This website also handles various devices bookings such as an Audio System, DJ, Lightning, Video Recording etc. Availability: The system also keeps track the information of the booking, whether it is available at chosen time or not.. - 43 -

4.6 PROCESS LOGIC FOR EACH MODULE Process Logic of Module is a tool that may be useful in planning and evaluating projects. Our logic model contains four components with Inputs-Outputs-Outcomes being central to the built in response to the model: Situation: The context and need that gives rise to a project or initiative; logic modules are built in response to an existing situation. Inputs: The resources, contributions, and investments that are made in response to the situation. Inputs lead to Outputs. Outputs: The activities, products, methods, and services that reach people and users. Outputs lead to outcomes. Outcomes: The results and benefits for individuals, groups, agencies, communities and/or systems. Report Generation The reports generated by the administrator are: Banquet Details Booking Status Login Details - 44 -

4.7 TOOLS / PLATFORM, HARDWARE AND SOFTWARE REQUIREMENT SPECIFICATION Hardware Interface:- Hardware Requirements: Number Description 1 PC with 20GB Hard-Disk and 256 MB RAM Software Interface Client on Internet: Window Browser, Operating System (any) Client on Intranet: Client Software, Window Browser, Operating System (any) Window Server: Operating System (any) Data Base Server: SQL database 2005, Operating System (any) Development End: JAVA with My SQL Development Environment:- Tool :- JAVA: Application Architecture MY SQL: Database Rational: Design Tool NETBEANS User Interface :- Java with My SQL - 45 -

4.8 SCHEDULING Scheduling of a software project does not differ greatly from scheduling of any multitask engineering effort. Therefore, generalized project scheduling tools and techniques can be applied with little modification to software projects. Program evaluation and review technique (PERT) and critical path method (CPM) are two project scheduling methods that can be applied to software development. Both techniques are driven by information already developed in earlier project planning activities. Estimates of Effort A decomposition of the product function. The selection of the appropriate process model and task set. Decomposition of tasks. Interdependencies among tasks may be defined using a task network. Tasks, sometimes called the project Work Breakdown Structure (WBS) are defined for the product as a whole or for individual functions. Both PERT and CPM provide quantitative tools that allow the software planner to (1) determine the critical path-the chain of tasks that determines the duration of the project; (2) establish "most likely" time estimates for individual tasks by applying statistical models; and (3) calculate "boundary times" that define a time window" for a particular task. Boundary time calculations can be very useful in software project scheduling. Slippage in the design of one function, for example, can retard further development of other functions. It describes important boundary times that may be discerned from a PERT or CPM network: (I) the earliest time that a task can begin when preceding tasks are completed in the shortest possible time, (2) the latest time for task initiation before the minimum project completion time is delayed, (3) the earliest finish-the sum of the earliest start and the task duration, (4) the latest finish- the latest start time added to task duration, - 46 -

and (5) the total float-the amount of surplus time or leeway allowed in scheduling tasks so that the network critical path maintained on schedule. Boundary time calculations lead to a determination of critical path and provide the manager with a quantitative method for evaluating progress as tasks are completed. Both PERT and CPM have been implemented in a wide variety of automated tools that are available for the personal computer. Such tools are easy to use and take the scheduling methods described previously available to every software project manager. - 47 -

- 48 -

5.1 SOURCE CODE Main.java /* * To change this template, choose Tools Templates * and open the template in the editor. */ package hotel; import java.sql.connection; import java.sql.drivermanager; import java.sql.statement; /** * * @author Rishi */ public class Mainmenu extends javax.swing.jframe { Connection con; Statement st; String nm, main; /** * Creates new form Mainmenu */ public Mainmenu() { initcomponents(); try { Class.forName("com.mysql.jdbc.Driver"); - 49 -

con=drivermanager.getconnection("jdbc:mysql://localhost:3307/bookingsystem","root","1234"); st=con.createstatement(); catch(exception e) { e.printstacktrace(); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jmenubar2 = new javax.swing.jmenubar(); jmenu3 = new javax.swing.jmenu(); jmenu4 = new javax.swing.jmenu(); jmenubar3 = new javax.swing.jmenubar(); jmenu5 = new javax.swing.jmenu(); jmenu6 = new javax.swing.jmenu(); jmenuitem1 = new javax.swing.jmenuitem(); jmenuitem2 = new javax.swing.jmenuitem(); jmenuitem3 = new javax.swing.jmenuitem(); jmenubar4 = new javax.swing.jmenubar(); jmenu8 = new javax.swing.jmenu(); jmenu9 = new javax.swing.jmenu(); jlabel3 = new javax.swing.jlabel(); jlabel1 = new javax.swing.jlabel(); jlabel2 = new javax.swing.jlabel(); jlabel4 = new javax.swing.jlabel(); jlabel5 = new javax.swing.jlabel(); jlabel6 = new javax.swing.jlabel(); jmenubar1 = new javax.swing.jmenubar(); jmenu1 = new javax.swing.jmenu(); jmenu2 = new javax.swing.jmenu(); jmenuitem4 = new javax.swing.jmenuitem(); jmenuitem5 = new javax.swing.jmenuitem(); jmenuitem7 = new javax.swing.jmenuitem(); jmenu7 = new javax.swing.jmenu(); jmenuitem10 = new javax.swing.jmenuitem(); jmenuitem9 = new javax.swing.jmenuitem(); jmenu10 = new javax.swing.jmenu(); - 50 -

jmenuitem6 = new javax.swing.jmenuitem(); jmenu11 = new javax.swing.jmenu(); jmenuitem8 = new javax.swing.jmenuitem(); jmenu3.settext("file"); jmenubar2.add(jmenu3); jmenu4.settext("edit"); jmenubar2.add(jmenu4); jmenu5.settext("file"); jmenubar3.add(jmenu5); jmenu6.settext("edit"); jmenubar3.add(jmenu6); jmenuitem1.settext("jmenuitem1"); jmenuitem2.settext("jmenuitem2"); jmenuitem3.settext("jmenuitem3"); jmenu8.settext("file"); jmenubar4.add(jmenu8); jmenu9.settext("edit"); jmenubar4.add(jmenu9); jlabel3.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel3.settext("online Booking System"); jlabel1.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel1.setforeground(new java.awt.color(102, 51, 255)); jlabel1.settext("allspark"); jlabel2.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel2.settext("banquet Hall "); setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); jlabel4.seticon(new javax.swing.imageicon(getclass().getresource("/sample Pictures/1.jpg"))); // NOI18N jlabel5.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel5.setforeground(new java.awt.color(153, 153, 0)); jlabel5.settext("allspark"); jlabel6.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel6.setforeground(new java.awt.color(204, 102, 0)); jlabel6.settext("banquet Hall "); - 51 -

jmenubar1.setforeground(new java.awt.color(102, 51, 255)); jmenu1.setforeground(new java.awt.color(153, 0, 255)); jmenu1.settext("home"); jmenu1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenu1actionperformed(evt); ); jmenubar1.add(jmenu1); jmenu2.setforeground(new java.awt.color(153, 0, 255)); jmenu2.settext("customer"); jmenuitem4.setbackground(new java.awt.color(153, 102, 255)); jmenuitem4.settext("booking"); jmenuitem4.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenuitem4actionperformed(evt); ); jmenu2.add(jmenuitem4); jmenuitem5.setbackground(new java.awt.color(153, 102, 255)); jmenuitem5.settext("cancellation"); jmenuitem5.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenuitem5actionperformed(evt); ); jmenu2.add(jmenuitem5); jmenuitem7.setbackground(new java.awt.color(153, 102, 255)); jmenuitem7.settext("community Halls"); jmenuitem7.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenuitem7actionperformed(evt); ); jmenu2.add(jmenuitem7); jmenubar1.add(jmenu2); jmenu7.setforeground(new java.awt.color(153, 0, 255)); jmenu7.settext("administration"); jmenuitem10.setbackground(new java.awt.color(153, 102, 255)); jmenuitem10.settext("admin"); jmenuitem10.addactionlistener(new java.awt.event.actionlistener() { - 52 -

public void actionperformed(java.awt.event.actionevent evt) { jmenuitem10actionperformed(evt); ); jmenu7.add(jmenuitem10); jmenuitem9.setbackground(new java.awt.color(153, 102, 255)); jmenuitem9.settext("community Halls"); jmenuitem9.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenuitem9actionperformed(evt); ); jmenu7.add(jmenuitem9); jmenubar1.add(jmenu7); jmenu10.setforeground(new java.awt.color(153, 0, 255)); jmenu10.settext("contact Us"); jmenu10.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenu10actionperformed(evt); ); jmenuitem6.settext("contact US"); jmenuitem6.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenuitem6actionperformed(evt); ); jmenu10.add(jmenuitem6); jmenubar1.add(jmenu10); jmenu11.setforeground(new java.awt.color(153, 0, 255)); jmenu11.settext("exit"); jmenuitem8.settext("exit"); jmenuitem8.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jmenuitem8actionperformed(evt); ); jmenu11.add(jmenuitem8); jmenubar1.add(jmenu11); setjmenubar(jmenubar1); - 53 -

javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(121, 121, 121).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel6).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addpreferredgap(javax.swing.layoutstyle.componentplacement.related, 9, javax.swing.grouplayout.preferred_size).addcomponent(jlabel5, javax.swing.grouplayout.preferred_size, 243, javax.swing.grouplayout.preferred_size).addgap(16, 16, 16))).addComponent(jLabel4)).addGap(0, 133, Short.MAX_VALUE)) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(24, 24, 24).addComponent(jLabel4, javax.swing.grouplayout.preferred_size, 186, javax.swing.grouplayout.preferred_size).addgap(18, 18, 18).addComponent(jLabel5, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addcomponent(jlabel6, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addcontainergap(70, Short.MAX_VALUE)) ); pack(); // </editor-fold> private void jmenuitem7actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new CommunityHall().setVisible(true); private void jmenuitem10actionperformed(java.awt.event.actionevent evt) { - 54 -

// TODO add your handling code here: Login p=new Login(); p.setvisible(true); private void jmenuitem9actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: Login p=new Login(); p.setvisible(true); private void jmenuitem4actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Mainmenu().setVisible(false); Booking o=new Booking(); o.setvisible(true); private void jmenuitem5actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Cancellation().setVisible(true); private void jmenu1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Mainmenu().setVisible(true); private void jmenu10actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jmenuitem6actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Contactus().setVisible(true); private void jmenuitem8actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: System.exit(0); - 55 -

/** * @param args the command line arguments */ public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.uimanager.setlookandfeel(info.getclassname()); break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(mainmenu.class.getname()).log(java.util.logging.lev el.severe, null, ex); catch (InstantiationException ex) { java.util.logging.logger.getlogger(mainmenu.class.getname()).log(java.util.logging.lev el.severe, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(mainmenu.class.getname()).log(java.util.logging.lev el.severe, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { java.util.logging.logger.getlogger(mainmenu.class.getname()).log(java.util.logging.lev el.severe, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Mainmenu().setVisible(true); ); // Variables declaration - do not modify private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; - 56 -

private javax.swing.jlabel jlabel4; private javax.swing.jlabel jlabel5; private javax.swing.jlabel jlabel6; private javax.swing.jmenu jmenu1; private javax.swing.jmenu jmenu10; private javax.swing.jmenu jmenu11; private javax.swing.jmenu jmenu2; private javax.swing.jmenu jmenu3; private javax.swing.jmenu jmenu4; private javax.swing.jmenu jmenu5; private javax.swing.jmenu jmenu6; private javax.swing.jmenu jmenu7; private javax.swing.jmenu jmenu8; private javax.swing.jmenu jmenu9; private javax.swing.jmenubar jmenubar1; private javax.swing.jmenubar jmenubar2; private javax.swing.jmenubar jmenubar3; private javax.swing.jmenubar jmenubar4; private javax.swing.jmenuitem jmenuitem1; private javax.swing.jmenuitem jmenuitem10; private javax.swing.jmenuitem jmenuitem2; private javax.swing.jmenuitem jmenuitem3; private javax.swing.jmenuitem jmenuitem4; private javax.swing.jmenuitem jmenuitem5; private javax.swing.jmenuitem jmenuitem6; private javax.swing.jmenuitem jmenuitem7; private javax.swing.jmenuitem jmenuitem8; private javax.swing.jmenuitem jmenuitem9; // End of variables declaration - 57 -

Booking.java /* * To change this template, choose Tools Templates * and open the template in the editor. */ package hotel; import java.sql.connection; import java.sql.drivermanager; import java.sql.resultset; import java.sql.statement; import javax.swing.joptionpane; import javax.swing.table.defaulttablemodel; /** * * @author Rishi */ public class Booking extends javax.swing.jframe { Connection con; Statement st; int i=0; String val; String radio; /** * Creates new form CommunityHalls */ public Booking() { initcomponents(); buttongroup1.add(jradiobutton4); - 58 -

buttongroup1.add(jradiobutton1); buttongroup1.add(jradiobutton2); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { buttongroup1 = new javax.swing.buttongroup(); jlabel3 = new javax.swing.jlabel(); jscrollpane1 = new javax.swing.jscrollpane(); jtable1 = new javax.swing.jtable(); jbutton1 = new javax.swing.jbutton(); jbutton2 = new javax.swing.jbutton(); jlabel1 = new javax.swing.jlabel(); jradiobutton4 = new javax.swing.jradiobutton(); jradiobutton1 = new javax.swing.jradiobutton(); jradiobutton2 = new javax.swing.jradiobutton(); jbutton3 = new javax.swing.jbutton(); jlabel2 = new javax.swing.jlabel(); jlabel4 = new javax.swing.jlabel(); jbutton4 = new javax.swing.jbutton(); jlabel12 = new javax.swing.jlabel(); jlabel13 = new javax.swing.jlabel(); jlabel3.setfont(new java.awt.font("tahoma", 1, 24)); // NOI18N jlabel3.setforeground(new java.awt.color(0, 0, 255)); jlabel3.settext("all Apark Booking Center"); setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); setbackground(new java.awt.color(204, 204, 255)); jtable1.setforeground(new java.awt.color(102, 0, 204)); jtable1.setmodel(new javax.swing.table.defaulttablemodel( new Object [][] { {null, null, null, null, null, null, null, {null, null, null, null, null, null, null, {null, null, null, null, null, null, null, {null, null, null, null, null, null, null, new String [] { "Name", "Address", "City ", "State", "Person", "Contact No.", "Facilities Available" - 59 -

)); jtable1.setgridcolor(new java.awt.color(102, 0, 204)); jscrollpane1.setviewportview(jtable1); jbutton1.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jbutton1.setforeground(new java.awt.color(102, 0, 204)); jbutton1.settext("display DATA"); jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt); ); jbutton2.setfont(new java.awt.font("arial", 0, 24)); // NOI18N jbutton2.setforeground(new java.awt.color(102, 0, 204)); jbutton2.settext("proceed"); jbutton2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton2actionperformed(evt); ); jlabel1.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel1.setforeground(new java.awt.color(102, 0, 204)); jlabel1.settext(" "); jradiobutton4.setforeground(new java.awt.color(102, 0, 204)); jradiobutton4.settext("check This Box For Basement Party"); jradiobutton4.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jradiobutton4actionperformed(evt); ); jradiobutton1.setforeground(new java.awt.color(102, 0, 204)); jradiobutton1.settext("check This Box For 1st Floor Main Hall Party"); jradiobutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jradiobutton1actionperformed(evt); ); jradiobutton2.setforeground(new java.awt.color(102, 0, 204)); jradiobutton2.settext("check This Box For Terrace Garden Party"); jradiobutton2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jradiobutton2actionperformed(evt); ); - 60 -

jbutton3.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jbutton3.setforeground(new java.awt.color(102, 0, 204)); jbutton3.settext("home"); jbutton3.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton3actionperformed(evt); ); jlabel2.setfont(new java.awt.font("times New Roman", 1, 14)); // NOI18N jlabel2.setforeground(new java.awt.color(255, 0, 0)); jlabel4.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel4.setforeground(new java.awt.color(153, 153, 0)); jlabel4.settext("for More Details About Halls And Their Availability"); jbutton4.setfont(new java.awt.font("tahoma", 1, 18)); // NOI18N jbutton4.setforeground(new java.awt.color(153, 0, 51)); jbutton4.settext("check Here..."); jbutton4.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton4actionperformed(evt); ); jlabel12.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel12.setforeground(new java.awt.color(153, 153, 0)); jlabel12.settext("allspark"); jlabel13.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel13.setforeground(new java.awt.color(204, 102, 0)); jlabel13.settext("banquet Hall "); javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(1208, 1208, 1208).addComponent(jLabel2, javax.swing.grouplayout.preferred_size, 203, javax.swing.grouplayout.preferred_size)).addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jscrollpane1, javax.swing.grouplayout.preferred_size, 682, javax.swing.grouplayout.preferred_size)).addgroup(layout.createsequentialgroup().addgap(265, 265, 265).addComponent(jButton2).addGap(67, 67, 67) - 61 -

.addcomponent(jbutton3, javax.swing.grouplayout.preferred_size, 99, javax.swing.grouplayout.preferred_size)).addgroup(layout.createsequentialgroup().addgap(200, 200, 200).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel1).addComponent(jLabel4, javax.swing.grouplayout.preferred_size, 412, javax.swing.grouplayout.preferred_size))).addgroup(layout.createsequentialgroup().addgap(340, 340, 340).addComponent(jButton4)).addGroup(layout.createSequentialGroup().addGap(318, 318, 318).addComponent(jLabel13)).addGroup(layout.createSequentialGroup().addGap(312, 312, 312).addComponent(jButton1)).addGroup(layout.createSequentialGroup().addGap(332, 332, 332).addComponent(jLabel12, javax.swing.grouplayout.preferred_size, 243, javax.swing.grouplayout.preferred_size)).addgroup(layout.createsequentialgroup().addgap(294, 294, 294).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jRadioButton1).addComponent(jRadioButton4).addComponent(jRadioButton2))) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jlabel12, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addcomponent(jlabel13, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addgap(18, 18, 18).addComponent(jScrollPane1, javax.swing.grouplayout.preferred_size, 92, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related, 11, Short.MAX_VALUE).addComponent(jButton1, javax.swing.grouplayout.preferred_size, 39, javax.swing.grouplayout.preferred_size).addgap(18, 18, 18).addComponent(jRadioButton4, javax.swing.grouplayout.preferred_size, 23, javax.swing.grouplayout.preferred_size) - 62 -

.addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addcomponent(jradiobutton1).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addcomponent(jradiobutton2).addgap(6, 6, 6).addComponent(jLabel2).addGap(15, 15, 15).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton2).addComponent(jButton3, javax.swing.grouplayout.preferred_size, 40, javax.swing.grouplayout.preferred_size)).addgap(33, 33, 33).addComponent(jLabel4).addGap(18, 18, 18).addComponent(jButton4, javax.swing.grouplayout.preferred_size, 23, javax.swing.grouplayout.preferred_size).addgap(15, 15, 15).addComponent(jLabel1, javax.swing.grouplayout.preferred_size, 26, javax.swing.grouplayout.preferred_size).addgap(22, 22, 22)) ); jbutton2.getaccessiblecontext().setaccessiblename("book"); pack(); // </editor-fold> private void jbutton1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: DefaultTableModel model = (DefaultTableModel) jtable1.getmodel(); // Clear the existing table int rows = model.getrowcount(); if (rows > 0) { for (int i = 0; i < rows; i++) { model.removerow(0); // SQL Query String query = "SELECT * FROM community"; try { // Connect to MySQL database Class.forName("com.mysql.jdbc.Driver").newInstance(); Connection con = (Connection) DriverManager.getConnection("jdbc:mysql://localhost:3307/bookingsystem","root","123 4"); // Create SQL statement and execute query. Statement stmt = con.createstatement(); - 63 -

ResultSet rs = stmt.executequery(query); // Iterate through the result and display on screen while (rs.next()) { String name = rs.getstring("commhall_name"); String add = rs.getstring("commhall_address"); String city = rs.getstring("commhall_city"); String state = rs.getstring("commhall_state"); String person = rs.getstring("commhall_person"); String contact = rs.getstring("contact_no."); String facilities = rs.getstring("facilities_available"); System.out.println(name + " " + add + " " + city + " " + state + " " +person+ " " +contact+ " " +facilities+ " "); model.addrow(new Object[] {name, add, city, state, person, contact, facilities); catch (Exception e) { JOptionPane.showMessageDialog(this, e.getmessage()); private void jradiobutton1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jradiobutton2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jradiobutton4actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jbutton2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: if(jradiobutton1.isselected()==true) { new Book("1st Floor Main Hall Party").setVisible(true); else if(jradiobutton2.isselected()==true) { new Book("Terrace Garden Party").setVisible(true); else if(jradiobutton4.isselected()==true) { - 64 -

new Book("Basement Party").setVisible(true); else { jlabel2.settext("please Check a Box"); private void jbutton3actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Booking().setVisible(false); Mainmenu c=new Mainmenu(); c.setvisible(true); private void jbutton4actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new CommunityHall().setVisible(true); /** * @param args the command line arguments */ public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.uimanager.setlookandfeel(info.getclassname()); break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(booking.class.getname()).log(java.util.logging.level. SEVERE, null, ex); catch (InstantiationException ex) { - 65 -

java.util.logging.logger.getlogger(booking.class.getname()).log(java.util.logging.level. SEVERE, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(booking.class.getname()).log(java.util.logging.level. SEVERE, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { java.util.logging.logger.getlogger(booking.class.getname()).log(java.util.logging.level. SEVERE, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Booking().setVisible(true); ); // Variables declaration - do not modify private javax.swing.buttongroup buttongroup1; private javax.swing.jbutton jbutton1; private javax.swing.jbutton jbutton2; private javax.swing.jbutton jbutton3; private javax.swing.jbutton jbutton4; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel12; private javax.swing.jlabel jlabel13; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; private javax.swing.jlabel jlabel4; private javax.swing.jradiobutton jradiobutton1; private javax.swing.jradiobutton jradiobutton2; private javax.swing.jradiobutton jradiobutton4; private javax.swing.jscrollpane jscrollpane1; private javax.swing.jtable jtable1; // End of variables declaration static class obj { - 66 -

Book.java /* * To change this template, choose Tools Templates * and open the template in the editor. */ package hotel; import java.sql.connection; import java.sql.drivermanager; import java.sql.resultset; import java.sql.statement; /** * * @author Rishi */ public class Book extends javax.swing.jframe { Connection con; Statement st; String rec; String b,c,d,e,f,g,h,n,j,k,l,m,p; String hall_type; /** * Creates new form Book */ public Book(String a) { initcomponents(); hall_type=a; int meb=100; - 67 -

try { Class.forName("com.mysql.jdbc.Driver"); con=drivermanager.getconnection("jdbc:mysql://localhost:3307/bookingsystem","root","1234"); st=con.createstatement(); String SQL = "SELECT * FROM booking"; // Connection string for ResultSet - rs. ResultSet rs = st.executequery(sql); while(rs.next()) { meb=integer.parseint(rs.getstring(1)); jlabel10.settext(string.valueof(meb+1)); jlabel11.settext(a); //Chosen Hall is passed from the previous page catch(exception e) { jlabel10.settext(string.valueof("")); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jmenuitem1 = new javax.swing.jmenuitem(); jmenuitem2 = new javax.swing.jmenuitem(); jmenuitem3 = new javax.swing.jmenuitem(); jlabel1 = new javax.swing.jlabel(); jlabel2 = new javax.swing.jlabel(); jlabel4 = new javax.swing.jlabel(); jlabel5 = new javax.swing.jlabel(); jlabel6 = new javax.swing.jlabel(); jlabel7 = new javax.swing.jlabel(); jlabel8 = new javax.swing.jlabel(); jlabel9 = new javax.swing.jlabel(); jbutton3 = new javax.swing.jbutton(); jtextfield1 = new javax.swing.jtextfield(); jlabel10 = new javax.swing.jlabel(); jtextfield2 = new javax.swing.jtextfield(); - 68 -

jcombobox1 = new javax.swing.jcombobox(); jcombobox2 = new javax.swing.jcombobox(); jcombobox3 = new javax.swing.jcombobox(); jcombobox4 = new javax.swing.jcombobox(); jcombobox5 = new javax.swing.jcombobox(); jcombobox6 = new javax.swing.jcombobox(); jbutton4 = new javax.swing.jbutton(); jlabel3 = new javax.swing.jlabel(); jlabel11 = new javax.swing.jlabel(); jlabel12 = new javax.swing.jlabel(); jlabel13 = new javax.swing.jlabel(); jtextfield3 = new javax.swing.jtextfield(); jlabel14 = new javax.swing.jlabel(); jlabel15 = new javax.swing.jlabel(); jmenuitem1.settext("jmenuitem1"); jmenuitem2.settext("jmenuitem2"); jmenuitem3.settext("jmenuitem3"); jlabel1.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel1.setforeground(new java.awt.color(102, 0, 255)); jlabel1.settext("all Spark Community Hall Online Booking System Welcomes You"); setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); jlabel2.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel2.setforeground(new java.awt.color(0, 153, 102)); jlabel2.settext("please Enter Your Details For Booking"); jlabel4.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel4.setforeground(new java.awt.color(102, 0, 255)); jlabel4.settext("member Id"); jlabel5.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel5.setforeground(new java.awt.color(102, 0, 255)); jlabel5.settext("email Id"); jlabel6.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel6.setforeground(new java.awt.color(102, 0, 255)); jlabel6.settext("date Of Booking"); jlabel7.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel7.setforeground(new java.awt.color(102, 0, 255)); jlabel7.settext("event "); jlabel8.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel8.setforeground(new java.awt.color(102, 0, 255)); - 69 -

jlabel8.settext("party Timings(Provide Approximately)"); jlabel9.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel9.setforeground(new java.awt.color(102, 0, 255)); jlabel9.settext("please Write Here For Any Other Queries or Contact Us"); jbutton3.setfont(new java.awt.font("arial", 0, 14)); // NOI18N jbutton3.setforeground(new java.awt.color(102, 0, 255)); jbutton3.settext("clear All Entries"); jbutton3.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton3actionperformed(evt); ); jtextfield1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield1actionperformed(evt); ); jlabel10.setfont(new java.awt.font("comic Sans MS", 1, 18)); // NOI18N jtextfield2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield2actionperformed(evt); ); jcombobox1.setfont(new java.awt.font("arial", 0, 11)); // NOI18N jcombobox1.setmodel(new javax.swing.defaultcomboboxmodel(new String[] { "DATE", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", " " )); jcombobox1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jcombobox1actionperformed(evt); ); jcombobox2.setmodel(new javax.swing.defaultcomboboxmodel(new String[] { "MONTH", "January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December", " " )); jcombobox2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jcombobox2actionperformed(evt); ); - 70 -

jcombobox3.setmodel(new javax.swing.defaultcomboboxmodel(new String[] { "YEAR", "2014", "2015", "2016", "2017", "2018", "2019", "2020" )); jcombobox4.setmodel(new javax.swing.defaultcomboboxmodel(new String[] { "SELECT", "Marriage", "Ring Ceremony", "Bussiness Party", "Kitty Party", "Birthday Party", "Satsang", "Chowki", "Other Party", " " )); jcombobox5.setmodel(new javax.swing.defaultcomboboxmodel(new String[] { "TIME", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12" )); jcombobox6.setmodel(new javax.swing.defaultcomboboxmodel(new String[] { "am/pm", "pm", "am" )); jbutton4.setfont(new java.awt.font("arial", 0, 14)); // NOI18N jbutton4.setforeground(new java.awt.color(102, 0, 255)); jbutton4.settext("book"); jbutton4.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton4actionperformed(evt); ); jlabel3.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel3.setforeground(new java.awt.color(102, 0, 255)); jlabel3.settext("hall Chosen"); jlabel11.setfont(new java.awt.font("comic Sans MS", 1, 18)); // NOI18N jlabel12.setfont(new java.awt.font("times New Roman", 1, 18)); // NOI18N jlabel12.setforeground(new java.awt.color(255, 0, 0)); jlabel12.settext(" "); jlabel13.setfont(new java.awt.font("times New Roman", 0, 14)); // NOI18N jlabel13.setforeground(new java.awt.color(102, 0, 255)); jlabel13.settext("contact Number"); jlabel14.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel14.setforeground(new java.awt.color(153, 153, 0)); jlabel14.settext("allspark"); jlabel15.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel15.setforeground(new java.awt.color(204, 102, 0)); jlabel15.settext("banquet Hall "); javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup() - 71 -

.addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(91, 91, 91).addComponent(jButton4).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED).addComponent(jButton3)).addGroup(layout.createSequentialGroup().addGap(29, 29, 29).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addcomponent(jlabel2, javax.swing.grouplayout.preferred_size, 511, javax.swing.grouplayout.preferred_size).addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addcomponent(jlabel14, javax.swing.grouplayout.preferred_size, 243, javax.swing.grouplayout.preferred_size).addgap(50, 50, 50)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(javax.swing.grouplayout.alignment.trailing, layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel5, javax.swing.grouplayout.preferred_size, 78, javax.swing.grouplayout.preferred_size).addcomponent(jlabel6).addcomponent(jlabel7, javax.swing.grouplayout.preferred_size, 46, javax.swing.grouplayout.preferred_size).addcomponent(jlabel8, javax.swing.grouplayout.preferred_size, 235, javax.swing.grouplayout.preferred_size).addcomponent(jlabel13, javax.swing.grouplayout.preferred_size, 151, javax.swing.grouplayout.preferred_size)).addgap(87, 87, 87)).addGroup(layout.createSequentialGroup() - 72 -

.addcomponent(jlabel3, javax.swing.grouplayout.preferred_size, 88, javax.swing.grouplayout.preferred_size).addgap(234, 234, 234))).addGroup(layout.createSequentialGroup().addComponent(jLabel4, javax.swing.grouplayout.preferred_size, 96, javax.swing.grouplayout.preferred_size).addgap(226, 226, 226))).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel10, javax.swing.grouplayout.preferred_size, 84, javax.swing.grouplayout.preferred_size).addcomponent(jlabel11, javax.swing.grouplayout.preferred_size, 266, javax.swing.grouplayout.preferred_size).addgroup(layout.createsequentialgroup().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jcombobox1, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox5, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jcombobox6, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addgroup(layout.createsequentialgroup().addcomponent(jcombobox2, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addcomponent(jcombobox3, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)))).addcomponent(jtextfield3, javax.swing.grouplayout.preferred_size, 169, javax.swing.grouplayout.preferred_size) - 73 -

.addcomponent(jtextfield1, javax.swing.grouplayout.preferred_size, 266, javax.swing.grouplayout.preferred_size).addcomponent(jtextfield2, javax.swing.grouplayout.preferred_size, 96, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox4, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size))).addgroup(layout.createsequentialgroup().addgap(279, 279, 279).addComponent(jLabel15))).addComponent(jLabel9, javax.swing.grouplayout.preferred_size, 327, javax.swing.grouplayout.preferred_size).addcomponent(jlabel12, javax.swing.grouplayout.preferred_size, 603, javax.swing.grouplayout.preferred_size)))).addcontainergap(315, Short.MAX_VALUE)) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jlabel14, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addcomponent(jlabel15, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addgap(1, 1, 1).addComponent(jLabel2, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading, false).addcomponent(jlabel4, javax.swing.grouplayout.default_size, 23, Short.MAX_VALUE).addComponent(jLabel10, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addcomponent(jlabel5, javax.swing.grouplayout.default_size, 24, Short.MAX_VALUE).addComponent(jTextField2)) - 74 -

.addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addcomponent(jlabel6, javax.swing.grouplayout.preferred_size, 26, javax.swing.grouplayout.preferred_size)).addgroup(layout.createsequentialgroup().addgap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jComboBox2, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox1, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox3, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)))).addgap(7, 7, 7).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel7, javax.swing.grouplayout.preferred_size, 21, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox4, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.baseline).addcomponent(jlabel8, javax.swing.grouplayout.preferred_size, 24, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox5, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addcomponent(jcombobox6, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.trailing).addcomponent(jlabel3) - 75 -

.addcomponent(jlabel11, javax.swing.grouplayout.preferred_size, 22, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.related, 81, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jLabel13, javax.swing.grouplayout.preferred_size, 19, javax.swing.grouplayout.preferred_size).addcomponent(jtextfield3)).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addcomponent(jlabel9, javax.swing.grouplayout.preferred_size, 29, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addcomponent(jlabel12).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.baseline).addcomponent(jbutton4, javax.swing.grouplayout.preferred_size, 34, javax.swing.grouplayout.preferred_size).addcomponent(jbutton3, javax.swing.grouplayout.preferred_size, 34, javax.swing.grouplayout.preferred_size))).addcomponent(jtextfield1, javax.swing.grouplayout.default_size, 153, Short.MAX_VALUE)).addContainerGap()) ); pack(); // </editor-fold> private void jcombobox2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jtextfield1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jbutton3actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: jtextfield2.settext(""); jtextfield1.settext(""); jcombobox1.setselecteditem("date"); jcombobox2.setselecteditem("month"); - 76 -

jcombobox3.setselecteditem("year"); jcombobox4.setselecteditem("select"); jcombobox5.setselecteditem("time"); jcombobox6.setselecteditem("am/pm"); private void jcombobox1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jtextfield2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jbutton4actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: int i=0,t=0; try { b=jlabel10.gettext(); c=jtextfield2.gettext(); d=jcombobox1.getselecteditem().tostring(); e=jcombobox2.getselecteditem().tostring(); f=jcombobox3.getselecteditem().tostring(); g=jcombobox4.getselecteditem().tostring(); h=jcombobox5.getselecteditem().tostring(); n=jcombobox6.getselecteditem().tostring(); j=jlabel11.gettext(); p=jtextfield3.gettext(); k=jtextfield1.gettext(); l=d+"-"+e+"-"+f; m=h+"-"+n; catch(exception e) { { try ResultSet res=st.executequery("select * from booking "); while(res.next()) { if(c.equals(res.getstring(2))) { i++; - 77 -

if(l.equals(res.getstring(3))) { t++; catch(exception e) { if(i>0 && t>0) { jlabel12.settext(" Email Id and Date of Booking already Exists"); else if(i>0 && t==0) { jlabel12.settext(" Email Id already Exists"); else if(i==0 && t>0) { jlabel12.settext(" Date of Booking already Exists"); else { try { int ch=0; st.executequery("select * FROM booking"); ch=st.executeupdate("insert INTO booking(member_id, Email_Id, Date_of_booking, Venue, Event, Timings,Contact_No,Queries) VALUES ('"+(b)+"','"+(c)+"','"+(l)+"','"+(j)+"','"+(g)+"','"+(m)+"','"+(p)+"','"+(k)+"')"); catch(exception e) { Register d=new Register(b,c,hall_type); //Member id (say b) and emailid (say c) is thrown to the register class d.setvisible(true); /** * @param args the command line arguments */ - 78 -

public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.uimanager.setlookandfeel(info.getclassname()); break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(book.class.getname()).log(java.util.logging.level.se VERE, null, ex); catch (InstantiationException ex) { java.util.logging.logger.getlogger(book.class.getname()).log(java.util.logging.level.se VERE, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(book.class.getname()).log(java.util.logging.level.se VERE, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { java.util.logging.logger.getlogger(book.class.getname()).log(java.util.logging.level.se VERE, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Book("").setVisible(true); ); // Variables declaration - do not modify private javax.swing.jbutton jbutton3; private javax.swing.jbutton jbutton4; private javax.swing.jcombobox jcombobox1; private javax.swing.jcombobox jcombobox2; private javax.swing.jcombobox jcombobox3; - 79 -

private javax.swing.jcombobox jcombobox4; private javax.swing.jcombobox jcombobox5; private javax.swing.jcombobox jcombobox6; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel10; private javax.swing.jlabel jlabel11; private javax.swing.jlabel jlabel12; private javax.swing.jlabel jlabel13; private javax.swing.jlabel jlabel14; private javax.swing.jlabel jlabel15; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; private javax.swing.jlabel jlabel4; private javax.swing.jlabel jlabel5; private javax.swing.jlabel jlabel6; private javax.swing.jlabel jlabel7; private javax.swing.jlabel jlabel8; private javax.swing.jlabel jlabel9; private javax.swing.jmenuitem jmenuitem1; private javax.swing.jmenuitem jmenuitem2; private javax.swing.jmenuitem jmenuitem3; private javax.swing.jtextfield jtextfield1; private javax.swing.jtextfield jtextfield2; private javax.swing.jtextfield jtextfield3; // End of variables declaration - 80 -

Registeration.java package hotel; import java.sql.*; import javax.swing.jpasswordfield; import javax.swing.joptionpane; /** * * @author Rishi */ public class Register extends javax.swing.jframe { Connection con; Statement st; String a,b,c,d; String hall; /** * Creates new form CustomerLogin */ public Register(String x,string y, String hall_type) { initcomponents(); jtextfield1.settext(y); jtextfield2.settext(x); hall=hall_type; try { Class.forName("com.mysql.jdbc.Driver"); con=drivermanager.getconnection("jdbc:mysql://localhost:3307/bookingsystem","root", "1234"); st=con.createstatement(); - 81 -

catch(exception e) { e.printstacktrace(); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jtextfield3 = new javax.swing.jtextfield(); jtextfield4 = new javax.swing.jtextfield(); jlabel1 = new javax.swing.jlabel(); jlabel2 = new javax.swing.jlabel(); jlabel3 = new javax.swing.jlabel(); jlabel4 = new javax.swing.jlabel(); jlabel5 = new javax.swing.jlabel(); jlabel6 = new javax.swing.jlabel(); jtextfield1 = new javax.swing.jtextfield(); jtextfield2 = new javax.swing.jtextfield(); jbutton1 = new javax.swing.jbutton(); jlabel7 = new javax.swing.jlabel(); jbutton3 = new javax.swing.jbutton(); pass = new javax.swing.jpasswordfield(); pass1 = new javax.swing.jpasswordfield(); setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); jlabel1.setfont(new java.awt.font("algerian", 1, 24)); // NOI18N jlabel1.setforeground(new java.awt.color(0, 0, 204)); jlabel1.settext(" EMAIL ID PROCESS "); jlabel2.setfont(new java.awt.font("algerian", 0, 18)); // NOI18N jlabel2.setforeground(new java.awt.color(0, 0, 204)); jlabel2.settext(" Please Provide a PASSWORD"); jlabel3.setforeground(new java.awt.color(51, 51, 255)); jlabel3.settext("email ID"); jlabel4.setforeground(new java.awt.color(51, 51, 255)); jlabel4.settext("member Id"); jlabel5.setforeground(new java.awt.color(51, 51, 255)); jlabel5.settext("password"); - 82 -

jlabel6.setforeground(new java.awt.color(51, 51, 255)); jlabel6.settext("confirm Password"); jtextfield1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield1actionperformed(evt); ); jtextfield2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield2actionperformed(evt); ); jbutton1.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jbutton1.setforeground(new java.awt.color(0, 0, 204)); jbutton1.settext("submit"); jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt); ); jlabel7.setforeground(new java.awt.color(255, 0, 0)); jbutton3.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jbutton3.setforeground(new java.awt.color(0, 0, 204)); jbutton3.settext("home"); jbutton3.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton3actionperformed(evt); ); javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel1, javax.swing.grouplayout.default_size, 455, Short.MAX_VALUE).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jLabel2, javax.swing.grouplayout.default_size, 445, Short.MAX_VALUE)).addGroup(layout.createSequentialGroup().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) - 83 -

.addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.trailing).addgroup(layout.createsequentialgroup().addcontainergap().addcomponent(jbutton1).addgap(41, 41, 41).addComponent(jButton3, javax.swing.grouplayout.preferred_size, 99, javax.swing.grouplayout.preferred_size).addgap(12, 12, 12)).addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createsequentialgroup().addgap(50, 50, 50).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addcomponent(jlabel5, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE).addComponent(jLabel4, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE).addComponent(jLabel3, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE).addComponent(jLabel6, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE)).addGap(79, 79, 79).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false).addcomponent(jtextfield2, javax.swing.grouplayout.default_size, 131, Short.MAX_VALUE).addComponent(jTextField1, javax.swing.grouplayout.default_size, 131, Short.MAX_VALUE).addComponent(pass).addComponent(pass1)))).addGroup(layout.createSequentialGroup().addGap(104, 104, 104).addComponent(jLabel7, javax.swing.grouplayout.preferred_size, 226, javax.swing.grouplayout.preferred_size))).addgap(0, 0, Short.MAX_VALUE)) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addcomponent(jlabel1, javax.swing.grouplayout.preferred_size, 51, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related) - 84 -

.addcomponent(jlabel2, javax.swing.grouplayout.preferred_size, 41, javax.swing.grouplayout.preferred_size).addgap(1, 1, 1).addComponent(jLabel7, javax.swing.grouplayout.preferred_size, 21, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.trailing).addgroup(layout.createsequentialgroup().addcomponent(jlabel3, javax.swing.grouplayout.preferred_size, 28, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addcomponent(jlabel4, javax.swing.grouplayout.preferred_size, 39, javax.swing.grouplayout.preferred_size)).addgroup(layout.createsequentialgroup().addcomponent(jtextfield1, javax.swing.grouplayout.preferred_size, 28, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addcomponent(jtextfield2, javax.swing.grouplayout.preferred_size, 30, javax.swing.grouplayout.preferred_size))).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.trailing).addcomponent(jlabel5, javax.swing.grouplayout.preferred_size, 33, javax.swing.grouplayout.preferred_size).addcomponent(pass, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.baseline).addcomponent(jlabel6, javax.swing.grouplayout.preferred_size, 36, javax.swing.grouplayout.preferred_size).addcomponent(pass1, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size)).addgap(18, 18, 18).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1).addComponent(jButton3, javax.swing.grouplayout.preferred_size, 40, javax.swing.grouplayout.preferred_size)).addcontainergap(23, Short.MAX_VALUE)) ); - 85 -

jlabel1.getaccessiblecontext().setaccessiblename("email ID PROCESS \n"); pack(); // </editor-fold> private void jtextfield1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jtextfield2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jbutton1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: a=jtextfield1.gettext(); b=jtextfield2.gettext(); c=new String(pass.getPassword()); d=new String(pass1.getPassword()); int rows,rows1; try { if(c.equals(d)) { rows=st.executeupdate("insert INTO login VALUES ('"+c+"','"+a+"','"+b+"')"); rows1=st.executeupdate("update community as c,booking as b SET c.status='booked',b.status='booked' where c.commhall_name='"+hall+"' and b.member_id='"+b+"' and c.commhall_name=b.venue "); if(rows==1 && rows1==1) { JOptionPane.showMessageDialog(this,"You event has been successfully booked "); new ThankYou().setVisible(true); else { JOptionPane.showMessageDialog(this,"You are successfully regtestered"); else { jlabel7.settext("passwords Do Not Match"); jtextfield3.settext(""); jtextfield4.settext(""); - 86 -

catch(exception e) { e.printstacktrace(); private void jbutton3actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Booking().setVisible(false); Mainmenu c=new Mainmenu(); c.setvisible(true); /** * @param args the command line arguments */ public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.uimanager.setlookandfeel(info.getclassname()); break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(register.class.getname()).log(java.util.logging.level. SEVERE, null, ex); catch (InstantiationException ex) { java.util.logging.logger.getlogger(register.class.getname()).log(java.util.logging.level. SEVERE, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(register.class.getname()).log(java.util.logging.level. SEVERE, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { - 87 -

java.util.logging.logger.getlogger(register.class.getname()).log(java.util.logging.level. SEVERE, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Register("","","").setVisible(true); ); // Variables declaration - do not modify private javax.swing.jbutton jbutton1; private javax.swing.jbutton jbutton3; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; private javax.swing.jlabel jlabel4; private javax.swing.jlabel jlabel5; private javax.swing.jlabel jlabel6; private javax.swing.jlabel jlabel7; private javax.swing.jtextfield jtextfield1; private javax.swing.jtextfield jtextfield2; private javax.swing.jtextfield jtextfield3; private javax.swing.jtextfield jtextfield4; private javax.swing.jpasswordfield pass; private javax.swing.jpasswordfield pass1; // End of variables declaration Cancelation.java /* * To change this template, choose Tools Templates * and open the template in the editor. */ package hotel; import java.sql.connection; import java.sql.drivermanager; import java.sql.resultset; import java.sql.statement; /** * * @author Rishi */ - 88 -

public class Cancellation extends javax.swing.jframe { Connection con; Statement st; String b; /** * Creates new form NewJFrame */ public Cancellation() { initcomponents(); try { Class.forName("com.mysql.jdbc.Driver"); con=drivermanager.getconnection("jdbc:mysql://localhost:3307/bookingsystem","root", "1234"); st=con.createstatement(); String SQL = "SELECT * FROM booking"; // Connection string for ResultSet - rs. catch(exception e) { e.printstacktrace(); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jlabel1 = new javax.swing.jlabel(); jlabel2 = new javax.swing.jlabel(); jtextfield1 = new javax.swing.jtextfield(); jlabel3 = new javax.swing.jlabel(); jbutton1 = new javax.swing.jbutton(); jlabel4 = new javax.swing.jlabel(); jlabel10 = new javax.swing.jlabel(); jlabel11 = new javax.swing.jlabel(); jbutton3 = new javax.swing.jbutton(); jlabel1.setfont(new java.awt.font("arial", 0, 24)); // NOI18N jlabel1.setforeground(new java.awt.color(102, 0, 204)); jlabel1.settext("please PROVIDE THE DETAILS FOR YOUR CANCELLATION"); - 89 -

setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); jlabel2.setfont(new java.awt.font("arial", 0, 24)); // NOI18N jlabel2.setforeground(new java.awt.color(102, 0, 204)); jlabel2.settext("enter The Email Id or Member Id Which You "); jlabel3.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel3.setforeground(new java.awt.color(102, 0, 204)); jlabel3.settext("registered With Us"); jbutton1.setfont(new java.awt.font("arial", 0, 14)); // NOI18N jbutton1.setforeground(new java.awt.color(102, 0, 255)); jbutton1.settext("cancel BOOKING"); jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt); ); jlabel4.setfont(new java.awt.font("comic Sans MS", 1, 18)); // NOI18N jlabel4.setforeground(new java.awt.color(255, 102, 0)); jlabel10.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel10.setforeground(new java.awt.color(153, 153, 0)); jlabel10.settext("allspark"); jlabel11.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel11.setforeground(new java.awt.color(204, 102, 0)); jlabel11.settext("banquet Hall "); jbutton3.setfont(new java.awt.font("arial", 0, 14)); // NOI18N jbutton3.setforeground(new java.awt.color(102, 0, 255)); jbutton3.settext("home"); jbutton3.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton3actionperformed(evt); ); javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addcontainergap().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup() - 90 -

.addgap(0, 197, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.trailing).addcomponent(jtextfield1, javax.swing.grouplayout.preferred_size, 155, javax.swing.grouplayout.preferred_size).addcomponent(jlabel3)).addgap(320, 320, 320)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addcomponent(jlabel2).addgap(173, 173, 173)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addcomponent(jlabel10, javax.swing.grouplayout.preferred_size, 243, javax.swing.grouplayout.preferred_size).addgap(264, 264, 264)))).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addcomponent(jlabel4, javax.swing.grouplayout.default_size, javax.swing.grouplayout.default_size, Short.MAX_VALUE).addContainerGap()))).addGroup(layout.createSequentialGroup().addGap(309, 309, 309).addComponent(jButton1).addGap(65, 65, 65).addComponent(jButton3, javax.swing.grouplayout.preferred_size, 99, javax.swing.grouplayout.preferred_size).addgap(0, 0, Short.MAX_VALUE)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addcontainergap(javax.swing.grouplayout.default_size, Short.MAX_VALUE).addComponent(jLabel11).addGap(254, 254, 254)) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(24, 24, 24).addComponent(jLabel10, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated) - 91 -

.addcomponent(jlabel11, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addgap(28, 28, 28).addComponent(jLabel2).addGap(18, 18, 18).addComponent(jLabel3, javax.swing.grouplayout.preferred_size, 39, javax.swing.grouplayout.preferred_size).addgap(32, 32, 32).addComponent(jTextField1, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related, 43, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jButton3, javax.swing.grouplayout.preferred_size, 40, javax.swing.grouplayout.preferred_size).addcomponent(jbutton1, javax.swing.grouplayout.preferred_size, 37, javax.swing.grouplayout.preferred_size)).addgap(27, 27, 27).addComponent(jLabel4, javax.swing.grouplayout.preferred_size, 45, javax.swing.grouplayout.preferred_size).addgap(20, 20, 20)) ); pack(); // </editor-fold> private void jbutton1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: int i=0,t=0; try { b=jtextfield1.gettext(); ResultSet res=st.executequery("select * from booking where member_id='"+b+"' or email_id='"+b+"'"); while(res.next()) { i++; catch(exception e) { e.printstacktrace(); if(i>0) { try { int ch=0; - 92 -

ch=st.executeupdate("update booking set status='cancelled' where Member_Id='"+b+"' or email_id='"+b+"' "); if(ch==1) { jlabel4.settext("your Booking Has Been Cancelled Thanks For Booking With All Spark Community Hall "); else { jlabel4.settext("your Booking Has Not Been Cancelled There Was Some Error "); catch(exception e) { e.printstacktrace(); else { jlabel4.settext(" Email Id Or Member Id is Not Registered with Us Please Contact The Community Hall "); private void jbutton3actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Booking().setVisible(false); Mainmenu c=new Mainmenu(); c.setvisible(true); /** * @param args the command line arguments */ public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { if ("Nimbus".equals(info.getName())) { - 93 -

javax.swing.uimanager.setlookandfeel(info.getclassname()); break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(cancellation.class.getname()).log(java.util.logging.l evel.severe, null, ex); catch (InstantiationException ex) { java.util.logging.logger.getlogger(cancellation.class.getname()).log(java.util.logging.l evel.severe, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(cancellation.class.getname()).log(java.util.logging.l evel.severe, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { java.util.logging.logger.getlogger(cancellation.class.getname()).log(java.util.logging.l evel.severe, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Cancellation().setVisible(true); ); // Variables declaration - do not modify private javax.swing.jbutton jbutton1; private javax.swing.jbutton jbutton3; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel10; private javax.swing.jlabel jlabel11; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; private javax.swing.jlabel jlabel4; private javax.swing.jtextfield jtextfield1; // End of variables declaration - 94 -

Communityhalls.java /* * To change this template, choose Tools Templates * and open the template in the editor. */ package hotel; import java.sql.connection; import java.sql.drivermanager; import java.sql.resultset; import java.sql.statement; import javax.swing.joptionpane; import javax.swing.table.defaulttablemodel; /** * * @author Rishi */ public class CommunityHall extends javax.swing.jframe { /** * Creates new form Booking */ public CommunityHall() { initcomponents(); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { - 95 -

jlabel1 = new javax.swing.jlabel(); jlabel10 = new javax.swing.jlabel(); jlabel11 = new javax.swing.jlabel(); jscrollpane1 = new javax.swing.jscrollpane(); jtable1 = new javax.swing.jtable(); jbutton1 = new javax.swing.jbutton(); jbutton2 = new javax.swing.jbutton(); jbutton3 = new javax.swing.jbutton(); jlabel1.setfont(new java.awt.font("tahoma", 0, 18)); // NOI18N jlabel1.setforeground(new java.awt.color(153, 153, 0)); jlabel1.settext("community Hall"); setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); jlabel10.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel10.setforeground(new java.awt.color(153, 153, 0)); jlabel10.settext("allspark"); jlabel11.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel11.setforeground(new java.awt.color(204, 102, 0)); jlabel11.settext("banquet Hall "); jtable1.setmodel(new javax.swing.table.defaulttablemodel( new Object [][] { {null, null, null, null, null, null, null, {null, null, null, null, null, null, null, {null, null, null, null, null, null, null, {null, null, null, null, null, null, null, new String [] { "Hall Name", "Address", "City", "Status", "Facilities Available", "Incharge", "Contact No." )); jscrollpane1.setviewportview(jtable1); jbutton1.setfont(new java.awt.font("times New Roman", 0, 18)); // NOI18N jbutton1.setforeground(new java.awt.color(0, 0, 255)); jbutton1.settext("view Hall Details"); jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt); ); jbutton2.setfont(new java.awt.font("tahoma", 0, 18)); // NOI18N jbutton2.setforeground(new java.awt.color(0, 0, 255)); jbutton2.settext("home"); jbutton2.addactionlistener(new java.awt.event.actionlistener() { - 96 -

public void actionperformed(java.awt.event.actionevent evt) { jbutton2actionperformed(evt); ); jbutton3.setfont(new java.awt.font("tahoma", 0, 18)); // NOI18N jbutton3.setforeground(new java.awt.color(0, 0, 255)); jbutton3.settext("go For Booking"); jbutton3.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton3actionperformed(evt); ); javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addcontainergap().addcomponent(jscrollpane1).addcontainergap()).addgroup(layout.createsequentialgroup().addgap(182, 182, 182).addComponent(jButton1, javax.swing.grouplayout.preferred_size, 180, javax.swing.grouplayout.preferred_size).addgap(18, 18, 18).addComponent(jButton3).addGap(27, 27, 27).addComponent(jButton2, javax.swing.grouplayout.preferred_size, 87, javax.swing.grouplayout.preferred_size).addcontainergap(77, Short.MAX_VALUE)).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addcontainergap(javax.swing.grouplayout.default_size, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jLabel11).addComponent(jLabel10, javax.swing.grouplayout.preferred_size, 243, javax.swing.grouplayout.preferred_size)).addgap(219, 219, 219)) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(40, 40, 40) - 97 -

.addcomponent(jlabel10, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.unrelated).addcomponent(jlabel11, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addgap(41, 41, 41).addComponent(jScrollPane1, javax.swing.grouplayout.preferred_size, 90, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related, 37, Short.MAX_VALUE).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1, javax.swing.grouplayout.preferred_size, 47, javax.swing.grouplayout.preferred_size).addcomponent(jbutton3, javax.swing.grouplayout.preferred_size, 48, javax.swing.grouplayout.preferred_size).addcomponent(jbutton2, javax.swing.grouplayout.preferred_size, 47, javax.swing.grouplayout.preferred_size)).addgap(34, 34, 34)) ); pack(); // </editor-fold> private void jbutton1actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: DefaultTableModel model = (DefaultTableModel) jtable1.getmodel(); // Clear the existing table int rows = model.getrowcount(); if (rows > 0) { for (int i = 0; i < rows; i++) { model.removerow(0); // SQL Query String query = "SELECT * FROM community"; try { // Connect to MySQL database Class.forName("com.mysql.jdbc.Driver").newInstance(); Connection con = (Connection) DriverManager.getConnection("jdbc:mysql://localhost:3307/bookingsystem","root","123 4"); // Create SQL statement and execute query. Statement stmt = con.createstatement(); ResultSet rs = stmt.executequery(query); // Iterate through the result and display on screen while (rs.next()) { - 98 -

String name = rs.getstring("commhall_name"); String add = rs.getstring("commhall_address"); String city = rs.getstring("commhall_city"); String state = rs.getstring("commhall_state"); String person = rs.getstring("commhall_person"); String contact = rs.getstring("contact_no."); String facilities = rs.getstring("facilities_available"); String status = rs.getstring("status"); System.out.println(name + " " + add + " " + city + " " + state + " " +person+ " " +contact+ " " +facilities+ " "); model.addrow(new Object[] {name, add, city, status, facilities, person, contact); catch (Exception e) { JOptionPane.showMessageDialog(this, e.getmessage()); private void jbutton3actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new CommunityHall().setVisible(false); Booking b = new Booking(); b.setvisible(true); private void jbutton2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Mainmenu().setVisible(true); /** * @param args the command line arguments */ public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.uimanager.setlookandfeel(info.getclassname()); - 99 -

break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(communityhall.class.getname()).log(java.util.loggin g.level.severe, null, ex); catch (InstantiationException ex) { java.util.logging.logger.getlogger(communityhall.class.getname()).log(java.util.loggin g.level.severe, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(communityhall.class.getname()).log(java.util.loggin g.level.severe, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { java.util.logging.logger.getlogger(communityhall.class.getname()).log(java.util.loggin g.level.severe, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new CommunityHall().setVisible(true); ); // Variables declaration - do not modify private javax.swing.jbutton jbutton1; private javax.swing.jbutton jbutton2; private javax.swing.jbutton jbutton3; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel10; private javax.swing.jlabel jlabel11; private javax.swing.jscrollpane jscrollpane1; private javax.swing.jtable jtable1; // End of variables declaration - 100 -

Admin.java package hotel; import java.sql.connection; import java.sql.drivermanager; import java.sql.resultset; import java.sql.statement; import java.awt.event.actionlistener; /** * * @author Rishi */ public class Login extends javax.swing.jframe { Connection con; Statement st; public Login() { initcomponents(); try { Class.forName("com.mysql.jdbc.Driver"); con=drivermanager.getconnection("jdbc:mysql://localhost:3307/bookingsystem","root","1234"); st=con.createstatement(); catch(exception e) { - 101 -

e.printstacktrace(); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jlabel4 = new javax.swing.jlabel(); jlabel5 = new javax.swing.jlabel(); user = new javax.swing.jradiobutton(); admin = new javax.swing.jradiobutton(); jlabel6 = new javax.swing.jlabel(); jlabel1 = new javax.swing.jlabel(); jlabel2 = new javax.swing.jlabel(); jtextfield1 = new javax.swing.jtextfield(); jtextfield2 = new javax.swing.jtextfield(); jbutton1 = new javax.swing.jbutton(); jlabel3 = new javax.swing.jlabel(); jlabel8 = new javax.swing.jlabel(); jlabel9 = new javax.swing.jlabel(); jbutton2 = new javax.swing.jbutton(); jlabel4.setfont(new java.awt.font("arial", 1, 24)); // NOI18N jlabel4.setforeground(new java.awt.color(102, 0, 255)); jlabel4.settext("community Hall "); jlabel5.setfont(new java.awt.font("arial", 0, 24)); // NOI18N jlabel5.setforeground(new java.awt.color(102, 0, 255)); jlabel5.settext("online Booking System"); user.setfont(new java.awt.font("tahoma", 0, 18)); // NOI18N user.setforeground(new java.awt.color(153, 153, 0)); user.settext("user"); admin.setfont(new java.awt.font("tahoma", 0, 18)); // NOI18N admin.setforeground(new java.awt.color(153, 153, 0)); admin.settext("admin"); jlabel6.setfont(new java.awt.font("tahoma", 0, 18)); // NOI18N jlabel6.setforeground(new java.awt.color(102, 0, 255)); jlabel6.settext("login As:"); setdefaultcloseoperation(javax.swing.windowconstants.exit_on_close); - 102 -

setbackground(new java.awt.color(51, 51, 255)); jlabel1.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel1.setforeground(new java.awt.color(102, 0, 255)); jlabel1.settext("adminname"); jlabel2.setfont(new java.awt.font("arial", 0, 18)); // NOI18N jlabel2.setforeground(new java.awt.color(102, 0, 255)); jlabel2.settext("password"); jtextfield2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jtextfield2actionperformed(evt); ); jbutton1.setfont(new java.awt.font("chiller", 1, 14)); // NOI18N jbutton1.setforeground(new java.awt.color(102, 0, 255)); jbutton1.settext("login"); jbutton1.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton1actionperformed(evt); ); jlabel3.setfont(new java.awt.font("times New Roman", 1, 14)); // NOI18N jlabel3.setforeground(new java.awt.color(255, 0, 0)); jlabel8.setfont(new java.awt.font("dialoginput", 1, 48)); // NOI18N jlabel8.setforeground(new java.awt.color(153, 153, 0)); jlabel8.settext("allspark"); jlabel9.setfont(new java.awt.font("engravers MT", 1, 24)); // NOI18N jlabel9.setforeground(new java.awt.color(204, 102, 0)); jlabel9.settext("banquet Hall "); jbutton2.setfont(new java.awt.font("comic Sans MS", 1, 14)); // NOI18N jbutton2.setforeground(new java.awt.color(102, 0, 255)); jbutton2.settext("home"); jbutton2.addactionlistener(new java.awt.event.actionlistener() { public void actionperformed(java.awt.event.actionevent evt) { jbutton2actionperformed(evt); ); javax.swing.grouplayout layout = new javax.swing.grouplayout(getcontentpane()); getcontentpane().setlayout(layout); layout.sethorizontalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading) - 103 -

.addgroup(layout.createsequentialgroup().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup().addgap(216, 216, 216).addComponent(jLabel8, javax.swing.grouplayout.preferred_size, 243, javax.swing.grouplayout.preferred_size)).addgroup(javax.swing.grouplayout.alignment.trailing, layout.createsequentialgroup().addgap(165, 165, 165).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createsequentialgroup().addgroup(layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addcomponent(jlabel3, javax.swing.grouplayout.preferred_size, 306, javax.swing.grouplayout.preferred_size).addgroup(layout.createsequentialgroup().addgap(20, 20, 20).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jLabel2).addComponent(jLabel1)).addGap(85, 85, 85).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jTextField1, javax.swing.grouplayout.preferred_size, 108, javax.swing.grouplayout.preferred_size).addcomponent(jtextfield2, javax.swing.grouplayout.preferred_size, 108, javax.swing.grouplayout.preferred_size)))).addgap(11, 11, 11)).addComponent(jLabel9, javax.swing.grouplayout.alignment.trailing)))).addgroup(layout.createsequentialgroup().addgap(234, 234, 234).addComponent(jButton1).addGap(44, 44, 44).addComponent(jButton2))).addContainerGap(153, Short.MAX_VALUE)) ); layout.setverticalgroup( layout.createparallelgroup(javax.swing.grouplayout.alignment.leading).addgroup(layout.createsequentialgroup() - 104 -

.addgap(30, 30, 30).addComponent(jLabel8, javax.swing.grouplayout.preferred_size, 44, javax.swing.grouplayout.preferred_size).addgap(28, 28, 28).addComponent(jLabel9, javax.swing.grouplayout.preferred_size, 35, javax.swing.grouplayout.preferred_size).addpreferredgap(javax.swing.layoutstyle.componentplacement.related).addcomponent(jlabel3, javax.swing.grouplayout.preferred_size, 55, javax.swing.grouplayout.preferred_size).addgap(8, 8, 8).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jTextField1, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addcomponent(jlabel1)).addgap(5, 5, 5).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jTextField2, javax.swing.grouplayout.preferred_size, javax.swing.grouplayout.default_size, javax.swing.grouplayout.preferred_size).addcomponent(jlabel2)).addgap(53, 53, 53).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(jButton1, javax.swing.grouplayout.preferred_size, 32, javax.swing.grouplayout.preferred_size).addcomponent(jbutton2, javax.swing.grouplayout.preferred_size, 32, javax.swing.grouplayout.preferred_size)).addcontainergap(80, Short.MAX_VALUE)) ); pack(); // </editor-fold> private void jtextfield2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: private void jbutton1actionperformed(java.awt.event.actionevent evt) { String name=null,pass=null; name=jtextfield1.gettext(); pass=jtextfield2.gettext(); try { - 105 -

ResultSet res=st.executequery("select * from Adminlogin where Username='"+name+"' and Password='"+pass+"'"); int i=0; while(res.next()) { i++; if(i>0) { new Login().setVisible(false); Admin o=new Admin(); o.setvisible(true); else { jlabel3.settext("invalid Adminname or Password"); jtextfield1.settext(""); jtextfield2.settext(""); catch(exception ett) { ett.printstacktrace(); private void jbutton2actionperformed(java.awt.event.actionevent evt) { // TODO add your handling code here: new Mainmenu().setVisible(true); /** * @param args the command line arguments */ public static void main(string args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.uimanager.lookandfeelinfo info : javax.swing.uimanager.getinstalledlookandfeels()) { - 106 -

if ("Nimbus".equals(info.getName())) { javax.swing.uimanager.setlookandfeel(info.getclassname()); break; catch (ClassNotFoundException ex) { java.util.logging.logger.getlogger(login.class.getname()).log(java.util.logging.level.s EVERE, null, ex); catch (InstantiationException ex) { java.util.logging.logger.getlogger(login.class.getname()).log(java.util.logging.level.s EVERE, null, ex); catch (IllegalAccessException ex) { java.util.logging.logger.getlogger(login.class.getname()).log(java.util.logging.level.s EVERE, null, ex); catch (javax.swing.unsupportedlookandfeelexception ex) { java.util.logging.logger.getlogger(login.class.getname()).log(java.util.logging.level.s EVERE, null, ex); //</editor-fold> /* Create and display the form */ java.awt.eventqueue.invokelater(new Runnable() { public void run() { new Login().setVisible(true); ); // Variables declaration - do not modify private javax.swing.jradiobutton admin; private javax.swing.jbutton jbutton1; private javax.swing.jbutton jbutton2; private javax.swing.jlabel jlabel1; private javax.swing.jlabel jlabel2; private javax.swing.jlabel jlabel3; private javax.swing.jlabel jlabel4; private javax.swing.jlabel jlabel5; private javax.swing.jlabel jlabel6; private javax.swing.jlabel jlabel8; private javax.swing.jlabel jlabel9; private javax.swing.jtextfield jtextfield1; private javax.swing.jtextfield jtextfield2; private javax.swing.jradiobutton user; // End of variables declaration - 107 -

Contactus.java /* * To change this template, choose Tools Templates * and open the template in the editor. */ package hotel; /** * * @author Rishi */ public class Contactus extends javax.swing.jframe { /** * Creates new form Contactus */ public Contactus() { initcomponents(); /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="generated Code"> private void initcomponents() { jlabel2 = new javax.swing.jlabel(); jlabel1 = new javax.swing.jlabel(); - 108 -