Sunteți pe pagina 1din 49

A PROJECT REPORT ON

On fulfillment of :-

Masters Degree in Information Technology


2004 2007
Under the guidance of : Submitted by:

Miss Archana Lal


AGARWAL

DEEPTI
M.Sc (IT) VI sem

Roll No.- 520433614

National Institute of Management & Computer Technology, Agra ( Sikkim Manipal University, Manipal)

CERTIFICATE
This is to certify that Deepti Agarwal student of M.Sc (IT) VI Sem has prepared her project

AIRLINE

RESERVATION SYSTEM

under my complete

guidance. She has prepared the project solely and the topic chosen by her has never been submitted anywhere for the award of any other degree. This project is a complete result of her hard work and dedication. I wish her best of luck for her endeavor.

Prashant Sagar (Director)

ACKNOWLEDGEMENT
No task is a single mans effort. Various factors, situations and persons Integrate to provide the background for accomplishment of a task. Several persons, with whom I interacted, have contributed significantly to the successful completion of the project study.

AIRLINE RESERVATION SYSTEM is the topic chosen by me to work on the


project report during my VI semester of M.Sc (IT) course. I thanks Miss Archana Lal for guiding me in this project and also for helping me throughout this project. Her invaluable guidance in steering the course of this

study, the patience and forbearance in updating my knowledge and preparation of this project is really credit worthy. I heartily thanks the honourable director sir Mr. Prashant Sagar of this institution for contributing his valuable time at my project and its approval. I am greatly indebted to my parents for extending me help as per my requirement.

INDEX

1. 2. 3. 4.

Introduction Front-End/ Platform to be used Back-End to be used Objective

5. 6. 7. 8. 9. 10.

Module Description Reconfirmation of Reservation & Cancellation Coding Layout Future Scope Bibliography

INTRODUCTION
In the world of break hassle, when we our struggling to get the things in a faster and easier way the airways has served a great purpose and the computers have contributed towards making the travel much more comfortable fast and quick. The computerized airline system not only provides with the immediate availability the vacant seat but also confirms the reservation and provides the agent with all other useful information whichever is required.

My project is based upon the online system of reservation, then query made by the agent, information regarding the seat availability, reservation and cancellation and such other further inquiry.

FRONT-END/ PLATFORM TO BE USED


With the advent of graphical Operating systems like Windows , the world of computing went through a dramatic change. It has open up a whole new world of graphics. Interfaces that use graphics came to be known as Graphical User Interface(GUI) . These became very popular because the users could identify with the graphics displayed on the screen .In every day life too, we associate more with images than words .

The primary requirement for an interface is that it is easy to use. We must be able to react intuitively to an interface presented to us. This is possible if the Interface presented is such that it emulates real life.

THE NEED FOR VISUAL PROGRAMMING :


There are several programming tools that allow us to build such visually appealing and intuitive interfaces. These tools allow us to design interfaces that employ user friendly features such as menu or buttons ,windows etc.

RAPID APPLICATION DEVELOPMENT TOOLS


Rapid application development (RAD) tool helps us to create such applications in a shorter time as compared to conventional language and with fewer errors. Rapid tool helps us to create a range of applications . These could range from a small utility for ourselves or workgroup to a larger enterprise wide system ,or even distributed applications spanning the globe via the Internet.

Visual Basic is a Microsofts RAD tool for Windows programmers


Visual Basic uses a graphical, formbased approach to application development .The typical way to write a program in visual basic is to create a form, drag and drop controls onto the form, set the properties for the form and its controls and add application specific code to handle events . It sounds simple ,but we can write some very popular applications in this manner. In case of large applications ,RAD tools enable the developers to

create a prototype of the large application. Such a prototype enables a user to understand the look and feel of the application.

VISUAL PROGRAMMING
Visual programming aims at providing the user with an interface that is intuitive and easy to use. In developing such an interface, the programmer employs user-friendly features such as windows, menus, buttons and list boxes. A visual programming environment provides all features that are required to develop a graphical user interface as ready to use components. The programmer does not have to write code to create and display commonly required user-friendly each time around. When the programmer needs a specific user interface such as button, he selects the appropriate ready to use component provided by the visual programming environment. These components can be moved ,resized and renamed as and when required .A Visual Programming environment automates the process of creating environment a user interface. The to the programmer interface is called provided the by programming interface, the visual

programmer design the user interface visually instead of writing code.

ADVANTAGES OF VISUAL PROGRAMMING


Visual programming enables :1. Visual development of graphical user interface which are easy to use and easy to learn . 2. A programmer need not write code to display the required component. 3. There is no restriction on the number of controls that can be placed on a form. 4. The interface components provided by the visual programming environment have some code built into them.

Some popular visual programming tools are :


1.Visual Basic 2.Power builder 3. Developer 2000.
Therefore the system will be built on windows 98 Platform with

Microsoft Visual Basic 6.0 as front end tool.

BACK-END TO BE USED
The project Category is

RDBMS (Relational Database

Management System)
As this Project will hold a lot of records; hence it will opt for RDBMS technology i.e. MS Access as Access database and is capable of holding

unlimited data and fetching, updating of records is fast compared to other technology. So, the backend used is MS Access 2000 and for form designing Visual Basic 6.0 is being used . Above Operating System will be Windows 2000 as it is NT based and there will be no problem on running MS Access database on Windows 2000.

OBJECTIVE

The objective of this project is to develop an online computerized reservation system for Airlines.

The main objective of this system is to provide reservation to passengers on request, to do cancellation of existing reservation reservations and also to provide adequate informations to passengers on request.

The proposed system will be capable of working on centralized data as well as remote data. The system also possesses the ability and the flexibility to be used by travel agents with a modifications.

MODULE DESCRIPTION
The project is divided into three main modules , as follows-

(a)THE RESERVATION PROCESS:The main working of this module is to accept the users request for seat reservation .It processes the request against seat availability and

issues the reservation if it exists otherwise denies the passenger request.

(b)THE CANCELLATION PROCESS:This module performs the work of reservation cancellation .It accepts the user request for cancellation , verifies the authenticity of request against the existing reservation and then cancelled the reservation there by refunding the amount as permissible.

( c)

THE

INFORMATION

REQUEST

PROCESS:The main function of this module is to give relevant information to users Query regarding Flight details like air-fare ,distance flight timings and days of operation ,seat availability etc. It accepts user query and process the same and gives the information or requested query.

RECONFIRAMTION OF RESERVATION , CANCELLATION

(1) GENERAL INFORAMTIONS :


If you hold an onward or return reservation, you are requested to reconfirm your reservation at least 72 hours before departure with the local gulf air

reservation office, failure to do so may result in cancellation of your booking.

(2) CANCELLATION OF RESERVATION :


If you have to cancel or defer your reservation, please let us know at the earliest possible moment and return your ticket. We can not guarantee the fare refundable for reservation canceled or transferred at short notice.

(3) GOVERNMENT FORMALITES


Passengers must comply with Government formalities in the countries of departure, transits and destination on the out word and return journey, and the company can not be held responsible for the failure to comply with any such regulations. Visa regulation exist throughout the gulf area and passengers are requested to check with their travel agents or the Embassy of the country to be visited.

(4) DANGEROUS GOODS IN PASSENGERS BAGGAGE :


Government regulations do not permit the carriage of briefcases and other cases with installed alarm devices, explosive, fireworks and flares, flammable items, flammable liquids, heating fuels, solids, which are easily

ignited. Such miscellaneous and magnetized materials and dangerous are listed in IATA-DANGEROUS-GOODS-

REGULATION. The only


exception is that where smoking is allowed on aircraft, you carry a small supply safety matches or liters on your person.

Of

Testing :During the testing of the system, we experiment with the system to ensure that the system could not fail in any condition. We confirm that software is running properly and it fulfills the expectations of the user. Some specific test data are prepared, then the system is tested on that data and the result, thus obtained, is examined. Testing helps in getting aware with the loopholes of the software. Basically there are 2 types of testing : Unit testing System testing

Unit Testing :Unit testing is also known as the program testing. In this type of testing each module of the software is tested separately. With this type of testing, it is easy to find small errors in the logic of the program.

System Testing :The error occurring during to common gap between user and designer, are checked and corrected in this type of testing. Here we consider all the likely validation that may apply in the software. In this testing we make logical assumptions for example if all the modules of the software are correct then it should be activated successfully. It consists following five steps : Program Testing String Testing System Testing Shifting Documentation User acceptance testing

The Test Plan :A plan is prepared to test all the aspects of the system in such a way that promotes the credibility of the software among the potential users. A test plan consists following activities : Prepare a test plan. Specify the conditions for user acceptance. Prepare the test data for program testing. Prepare test data for transaction path testing.

Make a plan for user training. Compile the program. Prepare the job performance aids. Prepare the oriental documents.

Implementation :The last and the most important phase in the system development life cycle is the implementation of new system. The implementation may have two meanings. One is to implement an all-new system that means there is no operational system to replace with. The second meaning is to replace the old system with the new system. To implement the system we have to perform following type of tasks : Planning Scheduling Change over

Planning:Before actually implementing the new system implementation must be planned. A timetable must be prepared that when and which subsystem should be replaced and who will be responsible for that.

Scheduling :Planning is basically an on paper job, while scheduling has the function just like loader that actually loads the program in the memory.

Various computer and non-computer tasks should be performed in scheduling. Change over: Last and final step of in the implementation phase is changeover. That means switching from one system to another system.

Types of Change over :Direct Change over :-

1.

In direct change over suddenly the old system is abolished and the new one is implemented. Therefore this type of changeover is preferable only fir small systems. 2.Pilot Change over: In this type of changeover things are changed according to the subsystems. When one subsystem is checked and proved OK only then the first one is eliminated. Hence in this technique subsystem are changed one by one.

3.Parallel changeover: This is the safest and the most costly technique. In this technique both old and new are run simultaneously. When everyone is satisfied only then the old system is eliminated.

To implement the Accounts and Stock Management System we need following things: The system should have the windows 9X platform. The system should have the Visual Basic 6.0. The system should have the MS-Access 2000.

CODING
MDIform.frm
Private Sub CMDEXIT_Click() Unload Me End Sub

Private Sub MNUAGENTQUERY_Click() Load agentq agentq.Show End Sub Private Sub MNUAGENTS_Click() Load frmagent frmagent.Show End Sub Private Sub MNUCANCELLATION_Click() Load frmcancellation frmcancellation.Show End Sub Private Sub MNURESERVATION_Click() Load frmreservation frmreservation.Show End Sub Private Sub MNUROUTES_Click() Load frmroutes frmroutes.Show End Sub Private Sub MUNRESERVATIONQUERY_Click() Load RESERVATIONQ RESERVATIONQ.Show End Sub

Password.frm
Option Explicit Private Sub cmdCancel_Click() Me.Hide End Sub Private Sub cmdOK_Click() If txtPassword Like "MAYANK" Then Me.Hide MDIForm1.Show Else MsgBox ("Invalid Password, try again!"), "Login" txtPassword.SetFocus txtPassword = ""

End If End Sub

AGENTQ.FRM
Dim find_str As String Dim cnn2 As Connection Dim rssearch As Recordset Private Sub CMDFIND_Click() find_str = "select * from agent " & + "where agentname =" + "'" + Text2.Text + "'" Set cnn2 = New ADODB.Connection cnn2.ConnectionString = "PROVIDER =MICROSOFT.JET.OLEDB.3.51;" & _ "DATA SOURCE=F:\1503\NISHITPROJECT\DINIS\PROJECT.mdb" cnn2.Open Set rssearch = New ADODB.Recordset rssearch.Open find_str, cnn2, adOpenDynamic, adLockOptimistic, adCmdText If rssearch.EOF And rssearch.BOF Then MsgBox "invalid agent name", vbOKOnly, "Stop!!" Exit Sub End If Text1.Text = rssearch![AGENTCODE] txtFields2(2).Text = rssearch![agentaddress] txtFields3(3).Text = rssearch![telphone] End Sub Private Sub cmdfirst_Click(Index As Integer) rssearch.MoveFirst DISPLAY End Sub Private Sub CMDLAST_Click(Index As Integer) rssearch.MoveLast DISPLAY End Sub Private Sub cmdnext_Click(Index As Integer) 'If rssearch.BOF Then rssearch.MoveNext 'DISPLAY 'Else 'MsgBox "No Records further" 'End If If Adodc1.Recordset.EOF = True Then

MsgBox "YOU ARE IN ALREADY ON LAST RECORD" Else Adodc1.Recordset.MoveNext End If End Sub Private Sub cmdpre_Click(Index As Integer) 'If rssearch.EOF Then rssearch.MovePrevious 'DISPLAY 'Else 'rssearch.MoveFirst 'End If If Adodc1.Recordset.BOF = True Then MsgBox "YOU ARE IN ALREADY IN FIRST RECORD" Else Adodc1.Recordset.MovePrevious End If End Sub Private Sub cmdClose_Click(Index As Integer) Screen.MousePointer = vbDefault Unload Me End Sub Private Sub Form_Unload(Cancel As Integer) 'cnn2.Close Unload Me End Sub Private Sub Text2_Click() Text2.Text = " " End Sub Private Sub Timer1_Timer() A = Rnd * 255 B = Rnd * 255 C = Rnd * 255 Label1.BackColor = RGB(A, B, C) End Sub Private Sub DISPLAY() Text1.Text = rssearch!AGENTCODE txtFields2(2).Text = rssearch!agentaddress

txtFields3(3).Text = Val(rssearch!telphone) End Sub

Frmagent.frm
Private Sub cmdadd_Click(Index As Integer) Dim find_str As String Dim cnn2 As ADODB.Connection Dim rssearch As ADODB.Recordset find_str = "select AGENTCODE from agent " Adodc1.Recordset.MoveLast R = Adodc1.Recordset![AGENTCODE] N = Val(Right(R, 3)) N=N+1 Adodc1.Recordset.AddNew If N < 10 Then Text1.Text = "AG00" + Str(N) End If If N >= 10 And N < 100 Then Text1.Text = "AG0" + Str(N) End If If N >= 100 And N < 999 Then Text1.Text = "AG" + Str(N) End If End Sub Private Sub cmdDelete_Click(Index As Integer) Dim RESPONSE As Integer MsgBox "DO YOU WANT TO DELETE THIS RECORD", vbOKCancel, "STOP!!" If RESPONSE = VBCANCLE Then Exit Sub With Adodc1.Recordset .Delete .MoveNext If .EOF Then .MoveLast End With End Sub Private Sub cmdfirst_Click(Index As Integer) Adodc1.Recordset.MoveFirst End Sub Private Sub CMDLAST_Click()

Adodc1.Recordset.MoveLast End Sub Private Sub cmdnext_Click() Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast End Sub Private Sub cmdpre_Click() Adodc1.Recordset.MovePrevious If Adodc1.Recordset.BOF Then Adodc1.Recordset.MoveFirst End Sub Private Sub cmdUpdate_Click(Index As Integer) Adodc1.Recordset.Update 'Adodc1.Recordset.Bookmark = Adodc1.Recordset.LastModified End Sub Private Sub cmdClose_Click(Index As Integer) Screen.MousePointer = vbDefault Unload Me End Sub Private Sub adodc1_Reposition() Screen.MousePointer = vbDefault On Error Resume Next Adodc1.Caption = "Record: " & (Adodc1.Recordset.AbsolutePosition + 1) End Sub Private Sub adodc1_Validate(Action As Integer, SAVE As Integer) Select Case Action Case vbDataActionMoveFirst Case vbDataActionMovePrevious Case vbDataActionMoveNext Case vbDataActionMoveLast Case vbDataActionAddNew Case vbDataActionUpdate Case vbDataActionDelete Case vbDataActionFind Case vbDataActionBookmark Case vbDataActionClose Screen.MousePointer = vbDefault End Select

Screen.MousePointer = vbHourglass End Sub Private Sub Form_Unload(Cancel As Integer) Screen.MousePointer = vbDefault End Sub Private Sub Timer1_Timer() A = Rnd * 255 B = Rnd * 255 C = Rnd * 255 Label1.BackColor = RGB(A, B, C) End Sub Private Sub txtFields1_KeyPress(Index As Integer, KeyAscii As Integer) If KeyAscii = 32 Then Exit Sub If IsNumeric(Chr(KeyAscii)) Or _ (KeyAscii >= 33 And KeyAscii <= 64) Or _ (KeyAscii >= 91 And KeyAscii <= 96) Or _ (KeyAscii >= 123 And KeyAscii <= 126) Then KeyAscii = 0 End If KeyAscii = Asc(UCase(Chr(KeyAscii))) End Sub Private Sub txtFields2_KeyPress(Index As Integer, KeyAscii As Integer) KeyAscii = Asc(UCase(Chr(KeyAscii))) End Sub Private Sub SAVE_Click() Adodc1.Recordset.Update End Sub Private Sub CANCLE_Click() Adodc1.Recordset.CancelUpdate End Sub Private Sub txtFields3_KeyPress(Index As Integer, KeyAscii As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0 MsgBox "telephone must be numeric", vbOKOnly, "stop!!"End If

Frmcancellation.frm
Dim find_str As String Dim cnn2 As ADODB.Connection Dim rssearch As ADODB.Recordset Private Sub cmdadd_Click(Index As Integer) Adodc1.Recordset.AddNew dt1.Text = "" End Sub Private Sub cmdDelete_Click(Index As Integer) Dim RESPONSE As Integer MsgBox "DO YOU WANT TO DELETE THIS RECORD", vbOKCancel, "STOP!!" If RESPONSE = VBCANCLE Then Exit Sub With Adodc1.Recordset .Delete .MoveNext If .EOF Then .MoveLast End With End Sub Private Sub cmdUpdate_Click(Index As Integer) Adodc1.Recordset.UpdateRecord 'Adodc1.Recordset.Bookmark = Adodc1.Recordset.LastModified End Sub Private Sub cmdClose_Click(Index As Integer) Screen.MousePointer = vbDefault Unload Me End Sub Private Sub cmdfirst_Click(Index As Integer) Adodc1.Recordset.MoveFirst End Sub Private Sub CMDLAST_Click() Adodc1.Recordset.MoveLast End Sub Private Sub cmdnext_Click() Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast End Sub Private Sub cmdpre_Click()

Adodc1.Recordset.MovePrevious If Adodc1.Recordset.BOF Then Adodc1.Recordset.MoveFirst End Sub Private Sub adodc1_Reposition() Screen.MousePointer = vbDefault On Error Resume Next Adodc1.Caption = "Record: " & (Adodc1.Recordset.AbsolutePosition + 1) End Sub Private Sub adodc1_Validate(Action As Integer, SAVE As Integer) Select Case Action Case vbDataActionMoveFirst Case vbDataActionMovePrevious Case vbDataActionMoveNext Case vbDataActionMoveLast Case vbDataActionAddNew Case vbDataActionUpdate Case vbDataActionDelete Case vbDataActionFind Case vbDataActionBookmark Case vbDataActionClose Screen.MousePointer = vbDefault End Select Screen.MousePointer = vbHourglass End Sub Private Sub dt1_LostFocus() Call find End Sub Private Sub Form_Activate() Text2.Text = Format(Date, "DD/MM/YYYY") End Sub Private Sub Form_Load() dt1.Text = " " Text3.Text = " " Text1.Text = " " txtFields3(3) = " " txtFields2(2) = " " txtFields4(4) = " "

txtFields1(1) = " " End Sub Private Sub SAVE_Click() Adodc1.Recordset.Update End Sub Private Sub CANCLE_Click() Adodc1.Recordset.CancelUpdate End Sub Private Sub Form_Unload(Cancel As Integer) Screen.MousePointer = vbDefault End Sub Public Sub find() find_str = "select * from reservation " & _ "where reservationnumber =" + "'" + dt1.Text + "'" Set cnn2 = New ADODB.Connection cnn2.ConnectionString = "PROVIDER =MICROSOFT.JET.OLEDB.3.51;" & _ "DATA SOURCE=F:\1503\NISHITPROJECT\DINIS\PROJECT.mdb" cnn2.Open Set rssearch = New ADODB.Recordset rssearch.Open find_str, cnn2, adOpenDynamic, adLockOptimistic, adCmdText If rssearch.EOF And rssearch.BOF Then MsgBox "invalid cancellation number", vbOKOnly, "Stop!!" Exit Sub End If txtFields1(1).Text = rssearch![flightnumber] txtFields2(2).Text = rssearch![AGENTCODE] Text1.Text = rssearch![AMOUNTOFONESEAT] Text3.Text = Format(rssearch![Date], "DD/MM/YYYY") cnn2.Close End Sub Private Sub Timer1_Timer() A = Rnd * 255 B = Rnd * 255 C = Rnd * 255 Label4.BackColor = RGB(A, B, C) End Sub Private Sub txtFields3_LostFocus(Index As Integer)

Dim A R = Format(Text3.Text, "DD/MM/YYYY") A = DateDiff("D", R, Text2.Text) If A >= 10 Then txtFields4(4) = 0.75 * txtFields3(3).Text * Text1.Text Else txtFields4(4) = 0.5 * txtFields3(3).Text * Text1.Text End If End Sub

Frmreservation.frm
Dim find_str As String Dim cnn2 As ADODB.Connection Dim rssearch As ADODB.Recordset Private Sub cmdadd_Click(Index As Integer) Adodc1.Recordset.AddNew End Sub Private Sub cmdDelete_Click(Index As Integer) Dim RESPONSE As Integer MsgBox "DO YOU WANT TO DELETE THIS RECORD", vbOKCancel, "STOP!!" If RESPONSE = VBCANCLE Then Exit Sub With Adodc1.Recordset .Delete .MoveNext If .EOF Then .MoveLast End With End Sub Private Sub cmdfirst_Click(Index As Integer) Adodc1.Recordset.MoveFirst End Sub Private Sub CMDLAST_Click() Adodc1.Recordset.MoveLast End Sub Private Sub cmdnext_Click() Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast End Sub

Private Sub cmdpre_Click() Adodc1.Recordset.MovePrevious If Adodc1.Recordset.BOF Then Adodc1.Recordset.MoveFirst End Sub Private Sub cmdUpdate_Click(Index As Integer) Adodc1.Recordset.UpdateRecord 'Adodc1.Recordset.Bookmark = Adodc1.Recordset.LastModified End Sub Private Sub cmdClose_Click(Index As Integer) Screen.MousePointer = vbDefault Unload Me End Sub Private Sub adodc1_Reposition() Screen.MousePointer = vbDefault On Error Resume Next Adodc1.Caption = "Record: " & (Adodc1.Recordset.AbsolutePosition + 1) End Sub Private Sub adodc1_Validate(Action As Integer, SAVE As Integer) Select Case Action Case vbDataActionMoveFirst Case vbDataActionMovePrevious Case vbDataActionMoveNext Case vbDataActionMoveLast Case vbDataActionAddNew Case vbDataActionUpdate Case vbDataActionDelete Case vbDataActionFind Case vbDataActionBookmark Case vbDataActionClose Screen.MousePointer = vbDefault End Select Screen.MousePointer = vbHourglass End Sub Private Sub Command1_Click() End Sub Private Sub DataCombo1_Click(Area As Integer) find_str = "select * from routes " & _

"where flightnumber =" + "'" + DataCombo1.Text + "'" Set cnn2 = New ADODB.Connection cnn2.ConnectionString = "PROVIDER =MICROSOFT.JET.OLEDB.3.51;" & _ "DATA SOURCE=F:\1503\NISHITPROJECT\DINIS\PROJECT.mdb" cnn2.Open Set rssearch = New ADODB.Recordset rssearch.Open find_str, cnn2, adOpenDynamic, adLockOptimistic, adCmdText If rssearch.EOF And rssearch.BOF Then MsgBox "invalid cancellation number", vbOKOnly, "Stop!!" Exit Sub End If Text1.Text = rssearch![AMOUNTOFONESEAT] cnn2.Close End Sub Private Sub SAVE_Click() Adodc1.Recordset.Update End Sub Private Sub CANCLE_Click() Adodc1.Recordset.CancelUpdate End Sub Private Sub Form_Unload(Cancel As Integer) Screen.MousePointer = vbDefault End Sub Private Sub Text1_KeyPress(KeyAscii As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0 MsgBox "AMOUNT OF ONE SEAT must be numeric", vbOKOnly, "stop!!" End If End Sub Private Sub Text2_GotFocus() If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0 End If Text2.Text = Val(txtFields3(3).Text * Text1.Text) End Sub

Private Sub txtFields_GotFocus(Index As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0 MsgBox " NUMBER OF SHEET must be numeric", vbOKOnly, "stop!!" End If End Sub Private Sub Timer1_Timer() A = Rnd * 255 B = Rnd * 255 C = Rnd * 255 Label3.BackColor = RGB(A, B, C) End Sub Private Sub txtFields2_Change(Index As Integer) End Sub Private Sub txtFields1_Click(Index As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0 MsgBox "tlephone must be numeric", vbOKOnly, "stop!!" End If End Sub Private Sub txtFields3_KeyPress(Index As Integer, KeyAscii As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) Then KeyAscii = 0 MsgBox "number of seats must be numeric", vbOKOnly, "stop!!" End If End Sub Private Sub txtFields4_Click(Index As Integer) 'txtFields4(5).Text = Format(Date, "DD/MM/YYYY") End Sub Private Sub txtFields4_GotFocus(Index As Integer) txtFields4(5).Text = Format(Date, "DD/MM/YYYY") End Sub Private Sub txtFields4_Validate(Index As Integer, Cancel As Boolean) If Not IsDate(txtFields4(5)) Then

MsgBox ("invalid date") Cancel = True End If End Sub

Frmroutes.frm
Private Sub CANCLE_Click() Adodc1.Recordset.CancelUpdate End Sub Private Sub cmdadd_Click(Index As Integer) Dim find_str As String Dim cnn2 As ADODB.Connection Dim rssearch As ADODB.Recordset find_str = "select FLIGHTNUMBER from ROUTES " Adodc1.Recordset.MoveLast R = Adodc1.Recordset![flightnumber] N = Val(Right(R, 3)) N=N+1 Adodc1.Recordset.AddNew If N < 10 Then txtFields1(0).Text = "FG00" + Str(N) End If If N >= 10 And N < 100 Then txtFields1(0).Text = "FG0" + Str(N) End If If N >= 100 And N < 999 Then txtFields1(0).Text = "FG" + Str(N) End If End Sub Private Sub cmdDelete_Click(Index As Integer) Dim RESPONSE As Integer MsgBox "DO YOU WANT TO DELETE THIS RECORD", vbOKCancel, "STOP!!" If RESPONSE = VBCANCLE Then Exit Sub With Adodc1.Recordset .Delete .MoveNext If .EOF Then .MoveLast

End With End Sub Private Sub cmdUpdate_Click(Index As Integer) Adodc1.Recordset.Update End Sub Private Sub cmdClose_Click(Index As Integer) Screen.MousePointer = vbDefault Unload Me End Sub Private Sub adodc1_Reposition() Screen.MousePointer = vbDefault On Error Resume Next Adodc1.Caption = "Record: " & (Adodc1.Recordset.AbsolutePosition + 1) End Sub Private Sub adodc1_Validate(Action As Integer, SAVE As Integer) Select Case Action Case vbDataActionMoveFirst Case vbDataActionMovePrevious Case vbDataActionMoveNext Case vbDataActionMoveLast Case vbDataActionAddNew Case vbDataActionUpdate Case vbDataActionDelete Case vbDataActionFind Case vbDataActionBookmark Case vbDataActionClose Screen.MousePointer = vbDefault End Select Screen.MousePointer = vbHourglass End Sub Private Sub cmdfirst_Click(Index As Integer) Adodc1.Recordset.MoveFirst End Sub Private Sub CMDLAST_Click() Adodc1.Recordset.MoveLast End Sub Private Sub cmdnext_Click()

Adodc1.Recordset.MoveNext If Adodc1.Recordset.EOF Then Adodc1.Recordset.MoveLast End Sub Private Sub cmdpre_Click() Adodc1.Recordset.MovePrevious If Adodc1.Recordset.BOF Then Adodc1.Recordset.MoveFirst End Sub Private Sub Command1_Click() Adodc1.Recordset.Update End Sub Private Sub Command2_Click() Adodc1.Recordset.CancelUpdate End Sub Private Sub Form_Unload(Cancel As Integer) Screen.MousePointer = vbDefault End Sub Private Sub txtFields_KeyPress(Index As Integer, KeyAscii As Integer) KeyAscii = Asc(UCase(Chr(KeyAscii))) End Sub Private Sub SAVE_Click() Adodc1.Recordset.Update End Sub Private Sub Timer1_Timer() A = Rnd * 255 B = Rnd * 255 C = Rnd * 255 Label2.BackColor = RGB(A, B, C) End Sub Private Sub txtFields2_KeyPress(Index As Integer, KeyAscii As Integer) If KeyAscii = 32 Then Exit Sub If IsNumeric(Chr(KeyAscii)) Or _ (KeyAscii >= 33 And KeyAscii <= 64) Or _ (KeyAscii >= 91 And KeyAscii <= 96) Or _ (KeyAscii >= 123 And KeyAscii <= 126) Then KeyAscii = 0 End If KeyAscii = Asc(UCase(Chr(KeyAscii)))

End Sub Private Sub txtFields3_KeyPress(Index As Integer, KeyAscii As Integer) If KeyAscii = 32 Then Exit Sub If IsNumeric(Chr(KeyAscii)) Or _ (KeyAscii >= 33 And KeyAscii <= 64) Or _ (KeyAscii >= 91 And KeyAscii <= 96) Or _ (KeyAscii >= 123 And KeyAscii <= 126) Then KeyAscii = 0 End If KeyAscii = Asc(UCase(Chr(KeyAscii))) End Sub Private Sub txtFields4_KeyPress(Index As Integer, KeyAscii As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) And KeyAscii <> 32 And KeyAscii <> 46 Then KeyAscii = 0 MsgBox "time must be numeric", vbOKOnly, "stop!!" End If End Sub Private Sub txtFields5_KeyPress(Index As Integer, KeyAscii As Integer) If Chr(KeyAscii) = vbBack Then Exit Sub If Not IsNumeric(Chr(KeyAscii)) And KeyAscii <> 32 And KeyAscii <> 46 Then KeyAscii = 0 MsgBox "time must be numeric", vbOKOnly, "stop!!" End If MsgBox "ARRIVAL TIME MUST BE SMALLER THAN DEPATURE TIME", vbOKOnly, "STOP!!" If txtFields5(4) < txtFields4(3) Then txtFields5(4) = " " End If End Sub

Reservation.frm
Dim find_str As String Dim cnn2 As Connection Dim rssearch As Recordset Private Sub Command1_Click() find_str = "select * from reservation " & _"where reservationnumber like " + "'" + Text3.Text + "'"

Set cnn2 = New ADODB.Connection cnn2.ConnectionString = "PROVIDER =MICROSOFT.JET.OLEDB.3.51;" & _" DATA SOURCE=F:\1503\NISHITPROJECT\DINIS\PROJECT.mdb" cnn2.Open Set rssearch = New ADODB.Recordset rssearch.Open find_str, cnn2, adOpenDynamic, adLockOptimistic, adCmdText If rssearch.EOF And rssearch.BOF Then MsgBox "invalid cancellation number", vbOKOnly, "Stop!!" Exit Sub End If Text4.Text = rssearch![flightnumber] Text5.Text = rssearch![AGENTCODE] Text1.Text = rssearch![AMOUNTOFONESEAT] Text2.Text = rssearch![TOTALAMOUNT] txtFields4(5).Text = rssearch![Date] txtFields3(3).Text = rssearch![NOOFSEATS] End Sub Private Sub cmdfirst_Click(Index As Integer) rssearch.MoveFirst End Sub Private Sub CMDLAST_Click(Index As Integer) rssearch.MoveLast End Sub Private Sub cmdnext_Click(Index As Integer) rssearch.MoveNext If rssearch.EOF = True Then MsgBox "You are already on the last record" End If End Sub Private Sub cmdpre_Click(Index As Integer) rssearch.MovePrevious If rssearch.BOF = True Then MsgBox "YOU ARE IN ALREADY IN FIRST RECORD" End If End Sub Private Sub cmdClose_Click(Index As Integer) Screen.MousePointer = vbDefault

Unload Me End Sub Private Sub Timer1_Timer() A = Rnd * 255 B = Rnd * 255 C = Rnd * 255 Label3.BackColor = RGB(A, B, C) End Sub Private Sub Command12_Click() End Sub Private Sub Form_Unload(Cancel As Integer) cnn2.Close End Sub Private Sub Text3_Click() Text3.Text = " " End Sub

Frmsplash.frm
Option Explicit Private Sub Form_KeyPress(KeyAscii As Integer) Unload Me End Sub Private Sub Frame1_Click() Unload Me End Sub Private Sub Timer1_Timer() Unload Me password.Show End Sub

LAYOUTS

FUTURE SCOPE

THIS

Proposed

Airline

Reservation

System

has been developed keeping in mind various future aspects. This

software thus possesses flexibility for future up gradation with much difficulty. The scope of future application is therefore very high. Some of them are quoted below. a) The software can be used by any Travel Agent and also by slight

modification. b) of c) The system can be used by the Airlines Booking Office to keep track reservation issued by the authorized travel Agent. This software has a flexibility to be used on centralized as well as

Distributed data using remote data action (same as used by the Railway Reservation System).

Thus depending upon the future requirements the software can be upgraded accordingly.

BIBLIOGRAPHY

1
2

Visual Basic 6.0 (Peter Nortons Guide to Visual Basic 6.0) Introduction to system analysis and design By I.T. Hawryszkiewycz System Analysis and Design By Elias M. Awad The User Interface concepts and design By L. Barfield Mastering Visual Basic By Evangelos Petroutsos

Websites :-

WWW.pcquest.com WWW.netsurf.com WWW.gogle.com WWW.rediff.com

S-ar putea să vă placă și