1.INTRODUCTION SYNOPSIS
The main aim of the project is to design des ign innovative software, which deals with the passport authority management. The motto of the project is to simplify the job of the administrative people and to render a user-friendly package.
The system provides information regarding the passport application and its status (enquiry). The tedious jobs such as verifying all the records of the applicant, confirming that all the personal details are furnished, submission of emigration emigration check documents, passing of police enquiry, enquiry, positive report from the previous applied section, etc., are done in the most convenient way to the administrator.
Also security is being provided in the most proficient way. way. All the intermediate stages starting from receiving of the application form to revealing the passport number along with the dispatch of the passport are being dealt.
1
2.SYSTEM ENVIRONMENT
HARDWARE HARDWARE SPECIFICATION
PROCESSOR
:
CELERON/PENTIUM 233 MHZ
RAM
:
32 MB
HARD DISK
:
2.1GB
FLOPPY DRIVE
: 1.44 MB
SOFWARE SPECIFICATION
OPERATING SYSTEM: MICROSOFT WINDOWS MILLENNIUM
: MS ACCESS 7.0
BACKEND FRONTEND
:
VISUAL BASIC 6.0
REPORT
:
DATA REPORTS
2
VISUAL BASIC 6.0 ENVIRONMENT Visual basic is the quickest and easiest way to create power powerfu full applic applicati ations ons for
Micros Microsoft oft operati operating ng system system.. The visual visual basic basic
programming system allows to create robust and useful applications that fully make make of the the grap graphi hica call user user inte interf rfac ace. e. Th Thee visu visual al basi basicc prog progra ramm mmin ing g is desc descen ende dent nt of basi basicc lang langua uage gess its its name name sugg suggest estss ,is ,is big big po port rtio ion n of the the programming with visual basic is accomplished visually . This means that during design time, we able to see how our program look during design. This is a great advantage over the other programming languages because we are also able to change change and experiment experiment with our design design until until we are satisfied satisfied with the colors, sizes, images that are indicated in in our program. program.
The visual basic language is quite powerful if we are able to remember a programming , task it can be probably accomplished using visual basic . In visual basic the “visual” part refers to the methods used to create the graphical user interface (GUI). Rather than writing numerous lines of code to describe the appearance and location of interface elements, we simply drag and and drop rebuilt objects and place on on the screen . If we have have ever used drawing program such as paint, we already have the most of the skill necessary skill to create in effective user interface
In visual basic the “basic” part refers to the basic language used by more more programmers programmers than any other language language in the history of 3
computing . Visual basic has evolved from the original BASIC languages and now contains several hundreds of statements, functions and key words ,many of whic which h rela relate te dire direct ctly ly to the the wind window owss UI. UI. Begi Beginn nner erss can can crea create te usef useful ul application by learning just a see of the keywords, yet the power of this language allows all the professionals to accomplished anything that can be also be accomplished using any other windows programming language.
The visual basic programming language is not unique to visual basic programming system . Applications edition included in Microsoft access, and many other windows applications use the language .the visual programming system, scripts edition internet programming is a subset of the visual basic language . The investment we make learning visual basic will carry over to these other areas. Whether our goal is to create a small utility for us or outwork group large enterprise-wide systems, or even to distributed application spanning the globe via internet. although it retains much of the user frie friend ndly ly , easy easy to use use feel feelin ing g of the the earl earlie ierr basi basic, c, by OT has has adde added d an immensely immensely rich rich and powerful powerful features features set with an incredible incredible capabilit capability y for exte extensi nsion on.. It’ It’s no now w cert certai ainl nly y po poss ssib ible le to desi design gn comp compli lies es visu visual al basi basicc applications in a high structured and rigorous fashion. The characteristics have helped helped to make world’s world’s best selling selling programming programming language language . visual basic as impl implem emen ente ted d ,let ,letss the the deve develo lope perr do almo almost st anyt anythi hing ng in almo almost st any any way way. particularly with all the third party tools that are others, is tremendous variety of ways to do almost any thing .this means that we can do things in right way or wrong way. visual basic wont stops us from designing the system badly. Ther Th eref efor oree , it is very very crit critic ical al to lear learn n and and make ake habi habitt of usin using g corr correc ectt programming and design design techniques. 4
1. Visual Visual Basic Basic code lines lines and comm comments ents
Normally , we enter visual basic on one line, meaning that end of the physical line indicates the end of the statement . Thus we can think of the lines as an usual implicit end of statement marker. This stand in contrast with usage in more highly structured languages . There is essentially no limit to theoretical length of visual basic statement entered this way on a single line. However , it is poor coding practice to create statements that don’t fit on one line is either a print out or the code window.
2. Uses of Visual Basic
Data access objects allows us to create database and front-end tools applic applicati ations ons for most most pop popula ularr databa database se forma formats, ts, includ including ing Micros Microsoft oft SQL SQL server and other enterprise-level database. ActiveX technologies allows us the functi functiona onalit lity y provid provided ed by the other other applic applicati ations ons ,such ,such as Micros Microsoft oft word word processor , Microsoft excel spread sheet, and other windows applications. We can even automate and objects created using the professional or enterprise edition of visual basic. internet capabilities make it easy to provide access to documents and applications across the internet from with n our applications. our finished application is a true exe file that users a run time dynamic link library (DLL) that we can freely describe.
5
3. Visual Basic Edition:
Visual Basic is available in three versions, each geared to meet a specific set of development requirements requirements . All are 32-bit applications. applications.
Learning edition
The visual basic learning edition allows the programmers too easily create powerful applications for Microsoft windows 95 and windows nt. includes all intrinsic controls, plus grid ,tab, and data bound controls.
Professional edition
The visual basic professional edition provides the computer professional with full –featured set of tools for developing solution for others. it includes all the features of learning edition , plus additional ActiveX controls ,including all internet controls , and the data report writer.
Enterprise edition
The visual visual basic basic enterp enterpris risee editio edition n allows allows profess profession ionals als to
create create robust robust
distributed applications in a term setting. it includes all the features of the professional edition ,plus the automation manager, component manager, data base base manage manageme ment nt tools tools,, the Micros Microsoft oft visual visual source source safe safe proje projectct-ori orient ented ed version control system and more.
6
ABOUT MS-ACCESS
Main Elements of Access:
Access is an object-oriented object-oriented program. Objects are modules, which provide information and programs, which the user can directly apply to create applications. Everything in access is an object, including the application itself. Each object has properties that define how the object looks and performs. Access has the following objects
1. Tables bles::
Tables are the primary building blocks of the access database. All data is stored in tables. Every table in the database focuses on one subject: subject : for example, customer, custo mer, order or products. Every row, or record in the table is a unique instance of the subject of the table.
2. Queries:
A query query is a question that you ask of the data that is stored in the tables of your database. For example, you you can create a query query that only asks for the customers who reside in the state of California or one that finds all employees who have have birthdays in the the current month. Most Access Databases contain more than one table. You You can combine specific fields from multiple multiple tables into one Datasheet. Datasheet. The Datasheet that a query query returns is called a record set. 7
3. Forms:
Forms present the data from a table or a query in the way it to be represented. The fields in the table table or query are made made available to a place place on the forms you create. You can edit the form just as you would edit a Datasheet bound table or query.
4. Reports:
Whether we like it or not, we are still a paper-based society, society, printing the results of the data we store. Reports are still necessary. necessary. With With Access, you can quickly and easily design reports based on your data. 5.Macros:
Macros provide an easy, effective method for automating many database tasks. You can use macros for everything from from displaying message boxes to validating data entered into a record before it is saved.
6. Modules
Modules are the containers for any programming code written in an Access Access database. The two types of modules in an Access database are global and form, or report.
8
3.SYSTEM SYSTE M ANALYSIS ANALYSIS Issuing of PASSPORT to the right citizen of the country with an unique number is the main function of the PASSPORT AUTHORITY (External Affairs). To avoid the tedious job of the administrators the whole system is being automated.
9
SYSTEM DEFINITION
At first, the applicant is given the application form. The applic applicant ant retur returns ns the applic applicati ation on du duly ly filled filled up with with all the detail details. s. After returning the application the administrator awards with a file number to that applicant. This file number plays the major role in the entire administrative procedure.
Using the file number administrator enters all the details such as personal personal informat information, ion, address address details, details, physical physical particul particulars ars and educationa educationall qualifications. If any one of these are found to be invalid then that particular section is stopped for process and the confirmation is being stopped.
Next section consists entirely of validating all the details like police records, validation of the amount paid, previous applied and submission of all the documents including the photos. Only if the concerned departments correctly approve all the reports then the file is sent to the passport writing section. Then the passport writing is done and dispatched. Also an ability of the applicant to enquire about the status of his application can be known through the enquiry section.
10
EXISTING SYSTEM The project contains following 4 modules.
1.NEW APPLICANT >SUBMITTING OF APPLICATION The input, process and output of this function are : INPUT : Application Application form is submitted duly filled with all details PROCESS : These values are stored in the database OUTPUT : A message confirmation stating the submission of application and issuing the file number is seen.
> SUBMITTING PERSONAL INFORMATION The input, process and output of this function are : INPUT : Personal information form is filled with all details PROCESS : These values are stored in the database OUTPUT : A message confirmation stating the submission of information is seen. > SUBMITTING ADDRESS DETAILS The input, process and output of this function are : INPUT :
Address Details form is filled with all details
PROCESS : These values are stored in the database OUTPUT : A message confirmation stating the submission of Address Details is seen.
> SUBMITTING PHYSICAL PARTICULARS 11
The input, process and output of this function are : INPUT : Physical Particulars form is filled with all details PROCESS : These values are stored in the database OUTP OUTPUT UT : A mess messag agee conf confir irma mati tion on stat statin ing g the the subm submis issi sion on of ph phys ysic ical al particulars is seen.
> SUBMITTING EDUCATIONAL QUALIFICATIONS The input, process and output of this function are : INPUT : Educational Qualifications form is filled with all details PROCESS : These values are stored in the database OUTPUT : A message confirmation stating the submission of Educational Qualifications is seen.
> SUBMITTING DOCUMENTS ENCLOSED The input, process and output of this function are : INPUT : Documents Enclosed form is filled with all details PROCESS : These values are checked for conformation and stored in the database OUTPUT OUTPUT : A messag messagee confir confirmat mation ion statin stating g the submi submissi ssion on of docume document ntss enclosed is seen.
> SUBMITTING FEE DETAILS The input, process and output of this function are : INPUT : Fee Details information form is filled with all details PROCESS : These values are checked for accuracy and then stored in the database 12
OUTPUT : A message confirmation stating the submission of fee details is seen.
> SUBMITTING POLICE INFORMATION The input, process and output of this function are : INPUT : Police Records form is filled with all details PROCESS : These values are checked for accuracy stored in the database OUTP OUTPUT UT : A mess messag agee conf confir irma mati tion on stat statin ing g the the subm submis issi sion on of po poli lice ce information is seen.
> SUBMITTING PREVIOUS APPLIED APPLIED The input, process and output of this function are : INPUT : Previous Applied form is filled with all details PROCESS : These values are checked for accuracy stored in the database OUTPUT : A message confirmation confirmation stating the submission of Previous Applied Applied is seen.
2.CONFIRMATION > RE-ENTERING OF THE DETAILS The input, process and output of this function are : INPUT : Appropriate Appropriate form is filled with all details PROCESS : These values are checked for accuracy stored in the database OUTPUT : A message message confirmation stating the submission of appropriate form is seen. 3.ENQUIRY >CHECK THE STATUS The input, process and output of this function are : 13
INPUT : The file number is given in the form. PROCESS : File number is checked in the database. OUTPUT : A message stating and the status is revealed .
4.REPORTS >PASSPORT WRITING The input, process and output of this function are : INPUT : The file number is given in the form. PROCESS : Only after all the conformation is positive, the database is updated and the expiry date is generated. Also the dispatch information is recorded in another database. OUTPUT : A report stating all the details of the passport holder is submitted. s ubmitted.
> UPTO DATE REPORT The input, process and output of this function are : INPUT : The DATE from which the needed details is being given. PROCESS : All the passport holders until the system date are checked in the database. OUTPUT : A report stating all the details of the passport holders is submitted. >INVALID DATA REPORT The input, process and output of this function are : INPUT : The file number is given in the form. PROCESS : Whenever the data is found to be insufficient then that particular record is searched. OUTP OUTPUT UT : A repo report rt stat statin ing g all all the the deta detail ilss of the the file file nu numb mber er ho hold lder er is submitted. 14
4.SYSTEM DESIGN
DAT DATA FLOW DIAGRAMS DIAG RAMS APPLICANT
DETIALS
SUBMIT APPLICATION
DETAILS
EXISTING APPLICANT
15
FILE NO
APPLICATION
DFD FOR EXISTING APPLICATION
EXISTING APPLICATION
SUBMIT INFORMATION
FILE NO
ENQUIRY CONFOR.
APPLICANT WITH DETAILS
DETAILS DETAILS DETAILS
PERSONAL DETAILS
ADDRESS DETAILS
PHYSICAL DETAILS
16
DETAILS
EDU. QUALIF.
DFD FOR ADMINISTRA ADMINIST RATION TION
EXISTING APPLICANT
FILE NO
CONFOR.
CHECKING RECORDS
ECNR
DOCUMENTS CHECKED APLLICATION
PREVIOUS APPLIED
POLICE RECORDS
DOCUMENT S ENCLOSED
17
FEE PARTICULAR
DFD FOR ENQUIRY
USER
FILE NO
CHECK FOR THE RECORD
DETAILS
FILE NO DETAILS
EN UIRY
18
USER WITH DETAILS
DATABASEDESIGN ADDRESS DETAILS
NAME OF FIELD FILENO PERMANENT
DATA TYPE T EX T T EX T
ADDRESS CITY STATE ZIPCODE PHONENO POLICESTATION POSTOFFICE
TEXT T EX T NUMBER NUMBER T EX T T EX T
WIDTH 10 50 15 15 7 12 20 20
DOCUMENTS ENCLOSED
NAME OF FIELD FILENO 7PHOTOS PLACEOFBIRTH CITIZENSHIPDOCUMENT
DATATYPE T EX T T EX T T EX T T EX T
WIDTH 15 5 20 15
APPLICATION FORM
NAME OF FIELD APPLICATIONNO CATEGORY APPLICANTNAME
DATATYPE TEXT TEXT TEXT
WIDTH 10 15 25 19
PLACEOFBIRTH DATEOFBIRTH AGE NATIONALITY SEX PRESENTADDRESS PERMANENTADDRESS PHONENO FILENO OLD
TEXT DATE/TIME NUMBER TEXT TEXT TEXT TEXT NUMBER TEXT TEXT
20 10 2 10 1 50 50 12 10 10
PREVIOUS APPLIED
NAME OF FIELD FILENO
DATATYPE T EX T
WIDTH 15
PHYSICAL PARTICULARS
NAME OF FIELD FILENO HEIGHT WEIGHT COLOROFEYES COLOROFHAIR IDENTIFICATIONMARK
DATATYPE TEXT NUMBER NUMBER TEXT TEXT TEXT
WIDTH 15 5 5 10 10 50
CONFIRMATION 20
NAME OF FIELD DATATYPE FILENO T EX T PERSONALINFORMATION T EX T ADDRESS T EX T PHYSICALPARTICULARS T EX T EDUCATIONALQUALIFICATIONS TEXT DOCUMENTSENCLOSED T EX T FEEDETAILS T EX T POLICERECORDS T EX T PREVIOUSAPPLIED T EX T
WIDTH 5 5 5 5 5 5 5 5 5
DISPATCH
NAME OF FIELD FILENO SPEEDPOSTNO DISPATCHDATE DELIVEREDADDRESS CITY STATE ZIPCODE
DATATYPE T EX T NUMBER DATE/TIME T EX T T EX T T EX T T EX T
WIDTH 15 15 12 50 20 15 7
EDUCATIONAL QUALIFICA QUAL IFICATION TION
NAME OF FIELD FILENO QUALIFICATION YEAROFPASSING UNIVERSITY
DATATYPE T EX T T EX T T EX T T EX T
WIDTH 15 20 20 30
21
EMMIGRATION CHECK
NAME OF FIELD FILENO GO DEGREE ITPAYEE PIV DAO
DATATYPE T EX T T EX T T EX T T EX T T EX T T EX T
WIDTH 5 5 5 5 5 5
ENQUIRY
NAME OF FIELD DATATYPE FILENO TEXT PERSONALINFROMATION TEXT ADDRESS TEXT PHYSICALPARTICULARS TEXT EDUCATIONALQUALIFICATION TEXT DOCUMENTSENCLOSED TEXT FEEDETAILS TEXT POLICERECORDS TEXT PREVIOUSAPPLIED TEXT PASSPORTWRITING TEXT DISPATCH TEXT
WIDTH 15 5 5 5 5 5 5 5 5 15 5
FEE PARTICULARS
NAME OF FIELD FILENO MODEOFPAYMENT
DATATYPE T EX T T EX T
WIDTH 15 7 22
AMOUNTPAID VALID
NUMBER T EX T
4 5
PERSONAL INFORMA INFORM ATION
NAME OF FIELD FILENO APPLICANTNAME FATHERNAME MOTHERNAME SPOUSENAME PLACEOFBIRTH SEX DATEOFBIRTH AGE NATIONALITY
DATATYPE T EX T T EX T T EX T T EX T T EX T T EX T T EX T DATE/TIME NUMBER T EX T
WIDTH 15 30 30 30 30 20 2 15 2 10
PASSPORT WRITING
NAME OF FIELD FILENO NAME NATIONALITY SEX DATEOFBIRTH PLACEOFBIRTH DATEOFISSUE DATEOFEXPIRY NAMEOFFATHER NAMEOFMOTHER
DATATYPE T EX T T EX T T EX T T EX T DATE/TIME T EX T DATE/TIME DATE/TIME T EX T T EX T
WIDTH 15 30 10 2 10 20 10 10 30 30 23
NAMEOFSPOUSE ADDRESS CITY STATE ZIPCODE EMMIGRATIONCHECK PASSPORTNO
T EX T T EX T T EX T T EX T NUMBER T EX T T EX T
30 50 20 15 7 15 15
POLICE RECORDS
NAME OF FIELD FILENO CONVICTED
DATATYPE T EX T T EX T
WIDTH 15 5
5.SYSTEM IMPLEMENTATION
SOURCE CODE OPENMENU
Private Sub Command1_Click() Command1_Click() MAINMENU.Show End Sub MAINMENU
Private Sub CMDLOGIN_Click() CMDLOGIN_Click() If (TXTUSERNAME.Text = "" And TXTPASSWORD.Text = "") Or (TXTUSERNAME.Text = "" And TXTPASSWORD.Text = "") Then PASSPORTAUTHORITY.Show Else 24
MsgBox ("UNSUCCESSFUL ("UNSUCCESSFUL LOGIN") TXTUSERNAME.Text = "" TXTUSERNAME.Text = "" TXTUSERNAME.SetFocus End If End Sub Private Sub CMDTERMINATE_Click() End End Sub Private Sub Timer1_Timer() Dim Today As Variant Today = Now Label1.Caption = Format(Today, "dddd") Label2.Caption = Format(Today, "dd/mm/yyyy") Label3.Caption = Format(Today, "h:mm:ss:ampm") End Sub Private Sub TXTPASSWORD_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then CMDLOGIN.SetFocus End If End Sub Private Sub TXTUSERNAME_KeyPr TXTUSERNAME_KeyPress(KeyAscii ess(KeyAscii As Integer) If KeyAscii = 13 Then TXTPASSWORD.SetFocus End If End Sub 25
ADDRESS DETAILS
Option Explicit Dim DB As Database Dim RST As Recordset Dim RST2 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST2(0) TXTPERMANENTADDRESS.Text = RST2(1) TXTCITY.Text TXTCITY.Text = RST2(2) RST 2(2) TXTSTATE.Text = RST2(3) TXTZIPCODE.Text = RST2(4) TXTPHONENO.Text = RST2(5) TXTPOLICEST TXTPOLICE STA ATION.Text = RST2(6) TXTPOSTOFFICE.Text = RST2(7) End Sub Private Sub FILLDB() RST2(0) = TXTFILENO.Text RST2(1) = TXTPERMANENTADDRESS.Text RST2(2) = TXTCITY TX TCITY.T .Text ext RST2(3) = TXTSTATE.Text RST2(4) = TXTZIPCODE.Text RST2(5) = TXTPHONENO.Text RST2(6) = TXTPOLICES T XTPOLICEST TATION.Text RST2(7) = TXTPOSTOFFICE.Text End Sub 26
Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or TXTPERMANENTADDRESS.Text = "" Or TXTCITY.Text = "" Or TXTSTATE.Text = "" Or TXTZIPCODE.Text = "" Or TXTPHONENO.Text = "" Or TXTPOLICESTATION.Text = "" Or TXTPOSTOFFICE.Text = "") Then MsgBox "U CANT SAVE THE FORM" Unload Me DETAILSOFAPPLICANT.Show Else RST2.MoveFirst While RST2.EOF <> True If RST2(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST2.MoveNext Wend RST2.AddNew FILLDB RST2.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(2) = "YES" 27
RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(2) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me DETAILSOFAPPLICANT.Show End If HEAVEN: Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command3 TXTFILENO.Text 28
DataReport3.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = DET DE TAILSOFAPPLICANT.TXTFILE AILSOFAPPLICANT.TXTFILENO.Text NO.Text Set RST2 = DB.OpenRecordset("ADDRESSDETAILS") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") Set RST = DB.OpenRecordset("APPLICATION") RST.MoveFirst While RST.EOF <> True If RST(11) = TXTFILENO.Text Then TXTFILENO.Enabled TXTFILENO.Enabled = False TXTPERMANENTADDRESS.Text = RST(9) TXTPHONENO.Text = RST(10) Else End If RST.MoveNext Wend End Sub Private Sub CMDEXIT_Click() Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub CMDFIRST_Click() 29
CMDSUBMIT.Enabled = False RST2.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False RST2.MoveLast FILLFORM End Sub Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST2.MoveNext If RST2.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False RST2.MovePrevious If RST2.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub 30
ADMINISTRATIVE VERIFICA VE RIFICATION TION Private Sub CMDBACK_Click() Unload Me Load DET D ETAILSOFAPPLICANT AILSOFAPPLICANT DETAILSOFAPPLICANT.Show End Sub Private Sub CMDDOCUMENTS_Click CMDDOCUMENTS_Click(Index (Index As Integer) If TXTFILENO.Text = "" Then MsgBox "ENTER THE FILE NUMBER" TXTFILENO.SetFocus Else Load DOCUMENTSENCLOSED DOCUMENTSENCLOSED.Show End If End Sub Private Sub CMDECNR_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER THE FILE NUMBER" TXTFILENO.SetFocus Else Load EMMIGRATIONCHECKNOTREQUIRED EMMIGRATIONCHECKNOTREQUIRED.Show End If End Sub Private Sub CMDEXIT_Click() Unload Me Load PASSPORTAUTHORITY 31
PASSPORTAUTHORITY.Show End Sub Private Sub CMDFEES_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER THE FILE NUMBER" TXTFILENO.SetFocus Else Load FEEPARTICULARS FEEPARTICULARS FEEPARTICULARS.Show End If End Sub
Private Sub CMDPOLICE_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER THE FILE NUMBER" TXTFILENO.SetFocus Else Load POLICERECORDS POLICERECORDS.Show End If End Sub Private Sub CMDPREVIOUS_Click() CMDPREVIOUS_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER THE FILE NUMBER" TXTFILENO.SetFocus Else Load PREVIOUSAPPLIED PREVIOUSAPPLIED 32
PREVIOUSAPPLIED.Show End If End Sub APPLICATION APPLICATION FORM Option Explicit Dim DB As Database Dim RST As Recordset Dim MM As Integer Dim RST13 As Recordset Dim RST14 As Recordset Dim D1 As Date
Private Sub CHKADDRESS_Click() CHKADDRESS_Click() If CHKADDRESS.Value = 1 Then TXTPERMANENTADDRESS.Text = TXTPRESENTADDRESS.Text TXTPHONENO.SetFocus Else If CHKADDRESS.Value = 0 Then TXTPERMANENTADDRESS = "" TXTPERMANENTADDRESS.SetFocus End If End If End Sub Private Sub CMDEXIT_Click() Unload Me 33
PASSPORTAUTHORITY.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False RST.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False RST.MoveLast FILLFORM End Sub
Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST.MoveNext If RST.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False RST.MovePrevious If RST.BOF Then MsgBox "THIS IS THE FIRST RECORD" 34
Else FILLFORM End If End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTAPPNO.Text = "" Or LSTCATEGORY.Text = "" Or TXTAPPLICANTNAME.Text = "" Or TXTPLACEOFBIRTH.Text = "" Or TXTDOB.Text = "" Or TXTNATION.Text = "" Or LSTSEX.Text = "" Or TXTPRESENTADDRESS.Text = "" Or TXTPERMANENTADDRESS.Text = "" Or TXTPHONENO.Text = "") Then MsgBox "INVALID APPLICATION -- DIDNT ENTER ALL THE FIELDS" Unload Me PASSPORTAUTHORITY.Show Else If Not (RST.EOF And RST.BOF) Then RST.MoveLast TXTFILENO = Val(RST(11)) + 1 Else TXTFILENO = "1000" End If FILLDB MM = RST(11) + 1 TXTFILENO.Text = MM MsgBox " YOUR YOUR FILE NUMBER IS IS -- " + Str(MM) RST13.AddNew RST13(0) = MM RST13(1) = "NO" 35
RST13(2) = "NO" RST13(3) = "NO" RST13(4) = "NO" RST13(5) = "NO" RST13(6) = "NO" RST13(7) = "NO" RST13(8) = "NO" RST13.Update RST14.AddNew RST14(0) = MM RST14(1) = "NO" RST14(1) = "NO" RST14(2) = "NO" RST14(3) = "NO" RST14(4) = "NO" RST14(5) = "NO" RST14(6) = "NO" RST14(7) = "NO" RST14(8) = "NO" RST14(9) = "NO" RST14(10) = "NO" RST14.Update MsgBox "RECORD SAVED IN CONF" PASSPORTAUTHORITY.Show End If End Sub Private Sub Form_Load() 36
Set DB = OpenDatabase(App.Path & "\passport.mdb") Set RST = DB.OpenRecordset("APPLICATION") Set RST13 = DB.OpenRecordset("CONFIRMATION") Set RST14 = DB.OpenRecordset("ENQUIRY") CLEARED End Sub Private Sub CLEARED() TXTAPPNO.Text TXTAPPNO.Text = "" "" LSTCA LSTC ATEGORY TEG ORY.Text .Text = "" TXTAPPLICANTNAME.Text = "" TXTPLACEOFBIRTH.Text = "" TXTDOB.Text = "" TXTAGE.Text TXTAGE.Text = "" "" TXTNATION.Text TXTNATION.Text = "" LSTSEX.Text = "" TXTPRESENTADDRESS.Text = "" TXTPERMANENTADDRESS.Text = "" TXTPHONENO.Text = "" TXTFILENO.Text = "" End Sub Private Sub FILLFORM() TXTAPPNO.Text = RST(0) LSTCATEGORY.Text = RST(1) TXTAPPLICANTNAME.Text = RST(2) TXTPLACEOFBIRTH.Text = RST(3) TXTDOB.Text = RST(4) TXTAGE.Text = RST(5) 37
TXTNATION.Text TXTNATION.Text = RST(6) RS T(6) LSTSEX.Text = RST(7) TXTPRESENTADDRESS.Text = RST(8) TXTPERMANENTADDRESS.Text = RST(9) TXTPHONENO.Text = RST(10) TXTFILENO.Text = RST(11) End Sub Private Sub FILLDB() RST.AddNew RST(0) = TXTAPPNO.Text TXTAPPNO.Text RST(1) = LSTCATEGORY.Text RST(2) = TXTAPPLICANTNAME.Text RST(3) = TXTPLACEOFBIRTH.Text RST(4) = TXTDOB.Text RST(5) = TXTAGE.Text TXTAGE.Text RST(6) = TXTNA TXT NATION.Text TION.Text RST(7) = LSTSEX.Text RST(8) = TXTPRESENTADDRESS.Text RST(9) = TXTPERMANENTADDRESS.Text RST(10) = TXTPHONENO.Text RST(11) = TXTFILENO.Text RST(12) = TXTOLD.Text RST.Update End Sub Private Sub LSTCATEGORY_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then TXTAPPLICANTNAME.SetFocus 38
End If End Sub Private Sub LSTCATEGORY_LostFocus() If LSTCATEGORY.Text = "RENEWAL" Then LBLOLD.Enabled = True TXTOLD.Enabled = True TXTOLD.SetFocus Else LBLOLD.Enabled = False TXTOLD.Enabled TXTOLD.Enabled = False TXTAPPLICANTNAME.SetFocus End If End Sub Private Sub LSTSEX_KeyPress(KeyAscii LSTSEX_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then TXTPRESENTADDRESS.SetFocus End If End Sub Private Sub TXTAPPLICANTNAME_K TXTAPPLICANTNAME_KeyPress(KeyAscii eyPress(KeyAscii As Integer) If KeyAscii = 13 Then TXTPLACEOFBIRTH.SetFocus End If End Sub Private Sub TXTAPPNO_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then LSTCATEGORY.SetFocus End If 39
End Sub Private Sub TXTDOB_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then TXTNATION.SetFocus End If End Sub Private Sub TXTDOB_LostFocus() D1 = TXTDOB TXTAGE.Text = DateDiff("YYYY", D1, Now) End Sub Private Sub TXTNATION_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then LSTSEX.SetFocus End If End Sub Private Sub TXTPERMANENTADDRESS_KeyPr TXTPERMANENTADDRESS_KeyPress(KeyAscii ess(KeyAscii As Integer) If KeyAscii = 13 Then TXTPHONENO.SetFocus End If End Sub Private Sub TXTPLACEOFBIRTH_KeyPress(Ke TXTPLACEOFBIRTH_KeyPress(KeyAscii yAscii As Integer) If KeyAscii = 13 Then TXTDOB.SetFocus End If End Sub Private Sub TXTPRESENTADDRESS_KeyP TXTPRESENTADDRESS_KeyPress(KeyAscii ress(KeyAscii As Integer) If KeyAscii = 13 Then 40
CHKADDRESS.SetFocus End If End Sub CONFORMATION CONFORMATION DETAILS DETAILS Option Explicit Dim DB As Database Dim RST14 As Recordset Dim T As Integer Private Sub CMDEXIT_Click() Unload Me PASSPORTAUTHORITY.Show End Sub
Private Sub CMDPASSPORTWRITING_Click() If (TXTPI.Text = "YES" And TXTADDRESS.Text = "YES" And TXTPHYSICALDETAILS.Text = "YES" And TXTEDUCA TXTEDUC ATIONALQUALIFICA TIONALQUA LIFICATIONS.Text TIONS.Text = "YES" And TXTDOCUMENTSENCLOSED.Text = "YES" And TXTFEEDETAILS.Text = "YES" And TXTPOLICECONFIRMATION.Text = "YES" And TXTPREVIOUSAPPLIED.Text = "YES") Then Load PASSPORTWRITING PASSPORTWRITING.Show Else MsgBox "ALL THE REQUIREMENTS ARE NOT SUBMITTED" PASSPORTAUTHORITY.Show End If End Sub 41
Private Sub Form_Load() Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") Set RST14 = DB.OpenRecordset("CONFIRMATION") End Sub Private Sub TXTFILENO_LostFocu TXTFILENO_LostFocus() s() T=0 RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then T=1 CLEARED TXTFILENO.Enabled TXTFILENO.Enabled = False TXTPI.Enabled = False TXTADDRESS.Enabled = False TXTPHYSICALDETAILS.Enabled = False TXTEDUCATIONALQUALIFICATIONS.Enabled = False TXTDOCUMENTSENCLOSED.Enabled TXTDOCUMENTSENCLOS ED.Enabled = False TXTFEEDETAILS.Enabled = False TXTPOLICECONFIRMATION.Enabled = False TXTPREVIOUSAPPLIED.Enabled TXTPREVIOUSAPPLIED.Enabled = False FILLFORM Else End If RST14.MoveNext Wend If T = 0 Then 42
MsgBox "NO SUCH FILE NUMBER EXISTS -- PLEASE SUBMIT UR APPLICATION" PASSPORTAUTHORITY.Show End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" TXTPI.Text = "" TXTADDRESS.Text = "" TXTPHYSICALDETAILS.Text = "" TXTEDUCA TXTEDUC ATIONALQUALIFICA TIONALQUA LIFICATIONS.Text TIONS.Text = "" TXTDOCUMENTSENCLOSED.Text = "" TXTFEEDETAILS.Text = "" TXTPOLICECONFIRMATION.Text = "" TXTPREVIOUSAPPLIED.Text = "" End Sub Private Sub FILLFORM() TXTFILENO.Text = RST14(0) TXTPI.Text = RST14(1) TXTADDRESS.Text = RST14(2) TXTPHYSICALDETAILS.Text = RST14(3) TXTEDUCA TXTEDUC ATIONALQUALIFICA TIONALQUA LIFICATIONS.Text TIONS.Text = RST14(4) R ST14(4) TXTDOCUMENTSENCLOSED.Text = RST14(5) TXTFEEDETAILS.Text = RST14(6) TXTPOLICECONFIRMATION.Text = RST14(7) TXTPREVIOUSAPPLIED.Text = RST14(8) End Sub 43
DETAILS OF APPLICANT Private Sub CMDADDRESS_Click() CMDADDRESS_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER FILE NUMBER" TXTFILENO.SetFocus Else Load ADDRESSDETAILS ADDRESSDETAILS.Show End If End Sub Private Sub CMDBACK_Click() Unload Me PASSPORTAUTHORITY.Show End Sub Private Sub CMDEDUQUALIFICATIONS_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER FILE NUMBER" TXTFILENO.SetFocus Else Load EDUCATIONALQUALI EDUCATIONALQUALIFICA FICATIONS TIONS EDUCATIONALQUALIFICATIONS.Show End If End Sub Private Sub CMDEXIT_Click() Unload Me PASSPORTAUTHORITY.Show End Sub 44
Private Sub CMDPERSONALINFORMATION_Click(Index As Integer) If TXTFILENO.Text = "" Then MsgBox "ENTER FILE NUMBER" TXTFILENO.SetFocus Else Load PERSONALINFORMATION PERSONALINFORMATION.Show End If End Sub Private Sub CMDPHYSICALPARTICULARS_Click() If TXTFILENO.Text = "" Then MsgBox "ENTER FILE NUMBER" TXTFILENO.SetFocus Else Load PHYSICALPARTICULARS PHYSICALPARTICULARS.Show End If End Sub DISPATCH DISPATCH DETAILS Option Explicit Dim DB As Database Dim RST11 As Recordset Dim RST8 As Recordset Dim RST13 As Recordset Private Sub CMDSAVE_Click()
45
If (TXTFILENO.Text = "" Or TXTSPEEDPOSTNO.Text = "" Or TXTDISPATCHDA TXTDISPATCHDATE.Text TE.Text = "" " " Or TXTDELIVEREDADDRE TXTDELIV EREDADDRESS.Text SS.Text = "" Or Text1.Text = "" Or Text2.Text = "" Or Text3.Text = "") Then MsgBox "U CAN'T SAVE THE FORM -- PLEASE ENTER ALL THE DETAILS" TXTSPEEDPOSTNO.SetFocus Else RST11.AddNew FILLDB RST11.Update MsgBox "RECORD SAVED" RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(10) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me PASSPORTAUTHORITY.Show End If End Sub Private Sub FILLDB() RST11(0) = TXTFILENO.Text 46
RST11(1) = TXTSPEEDPOSTNO.Text RST11(2) = TXTDISPATCHDATE.Text RST11(3) = TXTDELIVEREDADDRESS.Text RST11(4) = Text1.Text RST11(5) = Text2.Text RST11(6) = Text3.Text End Sub Private Sub Form_Load() Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") Set RST11 = DB.OpenRecordset("DISPATCH") Set RST13 = DB.OpenRecordset("ENQUIRY") Set RST8 = DB.OpenRecordset("EMMIGRATIONCHECK") TXTFILENO.Text = PASSPORTWRITING.TXTFILENO.Text TXTSPEEDPOSTNO.Text = "" TXTDISPA TXT DISPATCHD TCHDA ATE.T TE. Text = PASSPORTWRITING.TXTDATEOFISSUE.Text TXTDELIVEREDADDRESS.Text = PASSPORTWRITING.TXTADDRESS.Text Text1.Text = PASSPORTWRITING.Text1.Text Text2.Text = PASSPORTWRITING.Text2.Text Text3.Text = PASSPORTWRITING.Text3.Text End Sub DOCUMENTS ENCLOSED FORM Option Explicit Dim DB As Database Dim RST As Recordset Dim RST5 As Recordset 47
Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST5(0) LST7PHOTOS.Text = RST5(1) LSTPROOFOFDATEOFBIRTH.Text = RST5(2) LSTCITIZENSHIPDOCUMENT.Text = RST5(3) End Sub Private Sub FILLDB() RST5(0) = TXTFILENO.Text RST5(1) = LST7PHOTOS.Text RST5(2) = LSTPROOFOFDA LST PROOFOFDATEOFBIRTH.Text TEOFBIRTH.Text RST5(3) = LSTCITIZENSHIPDOCUMENT.Text End Sub
Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or LST7PHOTOS.Text = "" Or LSTPROOFOFDATEOFBIRTH.Text = "" Or LSTCITIZENSHIPDOCUMENT.Text = "" Or LST7PHOTOS.Text = "N" Or LSTPROOFOFDATEOFBIRTH.Text = "N" Or LSTCITIZENSHIPDOCUMENT.Text = "N") Then MsgBox "U CANT SAVE THE FORM" Unload Me ADMINISTRATIVEVERIFICATION.Show Else RST5.MoveFirst While RST5.EOF <> True 48
If RST5(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST5.MoveNext Wend
RST5.AddNew FILLDB RST5.Update MsgBox "RECORD SAVED"
RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(5) = "YES" RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit 49
RST13(5) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me ADMINISTRATIVEVERIFICATION.Show End If HEAVEN: Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub
Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command6 TXTFILENO.Text DataReport6.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = ADMINISTRATIVEVERIF ADMINISTRATIVEVERIFICA ICATION.TXT TION.TXTFILENO.Text FILENO.Text Set RST5 = DB.OpenRecordset("DOCUMENTSENCLOSED") DB.OpenRecordset("DOCUMENTSENCLOSED") 50
Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") End Sub Private Sub CMDEXIT_Click() Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST5.MoveFirst FILLFORM End Sub
Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED RST5.MoveLast FILLFORM End Sub Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST5.MoveNext If RST5.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM 51
End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST5.MovePrevious If RST5.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub
Private Sub CLEARED() TXTFILENO.Text = "" LST7PHOTOS.Text = "" LSTPROOFOFDA LSTPROOFOFD ATEOFBIRTH.Text = "" "" LSTCITIZENSHIPDOCUMENT.Text = "" End Sub EDUCATIONAL QUALIFICATIONS Option Explicit Dim DB As Database Dim RST As Recordset Dim RST4 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() 52
TXTFILENO.Text = RST4(0) TXTQUALIFICATION.Text = RST4(1) TXTYEAROFPASSING.Text = RST4(2) TXTUNIVERSITY TXTUNIVER SITY.Text .Text = RST4(3) RST4(3 ) End Sub Private Sub FILLDB() RST4(0) = TXTFILENO.Text RST4(1) = TXTQUALIFICATION.Text RST4(2) = TXTYEAROFPASSING.Text RST4(3) = TXTUNIVERSITY TXT UNIVERSITY.T .Text ext End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or TXTQUALIFICATION.Text = "" Or TXTYEAROFPASSING.Text = "" Or TXTUNIVERSITY.Text = "") Then MsgBox "U CANT SAVE THE FORM" Unload Me DETAILSOFAPPLICANT.Show Else RST4.MoveFirst While RST4.EOF <> True If RST4(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST4.MoveNext Wend 53
RST4.AddNew FILLDB RST4.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(4) = "YES" RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(4) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me DETAILSOFAPPLICANT.Show End If 54
HEAVEN: Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command5 TXTFILENO.Text DataReport5.Show End Sub
Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = DET DE TAILSOFAPPLICANT.TXTFILE AILSOFAPPLICANT.TXTFILENO.Text NO.Text Set RST4 = DB.OpenRecordset("EDUCATIONALQUALIFICATION") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") Set RST = DB.OpenRecordset("APPLICATION") End Sub Private Sub CMDEXIT_Click() Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub CMDFIRST_Click() 55
CMDSUBMIT.Enabled = False CLEARED RST4.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED RST4.MoveLast FILLFORM End Sub
Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST4.MoveNext If RST4.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST4.MovePrevious If RST4.BOF Then MsgBox "THIS IS THE FIRST RECORD" 56
Else FILLFORM End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" TXTQUALIFICATION.Text = "" TXTYEAROFPASSING.Text = "" TXTUNIVERSITY TXTUNIVER SITY.Text .Text = "" End Sub EMMIGRATION CHECK NOT REQUIRED FORM
Option Explicit Dim DB As Database Dim RST8 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST8(0) LSTGO.Text = RST8(1) LSTDEGREE.Text = RST8(2) LSTITPA LSTITPAYEE.Text = RST8(3) LSTPIV.T LSTPIV.Text ext = RST8(4) RS T8(4) LSTDAO.Text = RST8(5) End Sub Private Sub FILLDB() RST8(0) = TXTFILENO.Text RST8(1) = LSTGO.Text RST8(2) = LSTDEGREE.Text 57
RST8(3) = LSTITPAYEE.Text LSTITPAYEE.Text RST8(4) = LSTPIV L STPIV.Text .Text RST8(5) = LSTDAO.Text End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or LSTGO.Text = "" Or LSTDEGREE.Text = "" Or LSTITPAYEE.Text = "" Or LSTPIV.Text = "" Or LSTDAO.Text = "" Or (LSTGO.Text = "N" And LSTDEGREE.Text = "N" And LSTITPAYEE.Text = "N" And LSTPIV.Text = "N" And LSTDAO.Text = "N")) Then MsgBox "U CAN'T SAVE THE FORM" Unload Me ADMINISTRATIVEVERIFICATION.Show Else RST8.MoveFirst While RST8.EOF <> True If RST8(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST8.MoveNext Wend RST8.AddNew FILLDB RST8.Update MsgBox "RECORD SAVED" Unload Me 58
ADMINISTRATIVEVERIFICATION.Show End If HEAVEN: Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = ADMINISTRATIVEVERIF ADMINISTRATIVEVERIFICA ICATION.TXT TION.TXTFILENO.Text FILENO.Text Set RST8 = DB.OpenRecordset("EMMIGRATIONCHECK") End Sub Private Sub CMDEXIT_Click() Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST8.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED RST8.MoveLast 59
FILLFORM End Sub Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST8.MoveNext If RST8.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub
Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST8.MovePrevious If RST8.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" LSTGO.Text = "" LSTDEGREE.Text = "" LSTITPAYEE.Text = "" 60
LSTPIV.Text = "" LSTDAO.Text = "" End Sub ENQUIRY DETAILS DETAILS FORM FO RM Option Explicit Dim DB As Database Dim RST13 As Recordset Dim T As Integer Private Sub CMDEXIT_Click() Unload Me PASSPORTAUTHORITY.Show End Sub Private Sub Form_Load() Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") Set RST13 = DB.OpenRecordset("ENQUIRY") End Sub Private Sub TXTFILENO_LostFocu TXTFILENO_LostFocus() s() T=0 RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then T=1 CLEARED TXTFILENO.Enabled TXTFILENO.Enabled = False TXTPI.Enabled = False TXTADDRESS.Enabled = False TXTPHYSICALDETAILS.Enabled = False 61
TXTEDUCATIONALQUALIFICATIONS.Enabled = False TXTDOCUMENTSENCLOSED.Enabled TXTDOCUMENTSENCLOS ED.Enabled = False TXTFEEDETAILS.Enabled = False TXTPOLICECONFIRMATION.Enabled = False TXTPREVIOUSAPPLIED.Enabled TXTPREVIOUSAPPLIED.Enabled = False TXTPASSPORTWRITING.Enabled = False TXTDISPATCH.Enab TXTDISPATCH.Enabled led = False FILLFORM Else End If RST13.MoveNext Wend If T = 0 Then MsgBox "NO SUCH FILE NUMBER EXISTS -- PLEASE SUBMIT UR APPLICATION" PASSPORTAUTHORITY.Show End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" TXTPI.Text = "" TXTADDRESS.Text = "" TXTPHYSICALDETAILS.Text = "" TXTEDUCA TXTEDUC ATIONALQUALIFICA TIONALQUA LIFICATIONS.Text TIONS.Text = "" TXTDOCUMENTSENCLOSED.Text = "" TXTFEEDETAILS.Text = "" TXTPOLICECONFIRMATION.Text = "" 62
TXTPREVIOUSAPPLIED.Text = "" TXTPASSPORTWRITING.Text TXTPASSPORTWRITING.Text = "" TXTDISPATCH.Text = "" End Sub Private Sub FILLFORM() TXTFILENO.Text = RST13(0) TXTPI.Text = RST13(1) TXTADDRESS.Text = RST13(2) TXTPHYSICALDETAILS.Text = RST13(3) TXTEDUCA TXTEDUC ATIONALQUALIFICA TIONALQUA LIFICATIONS.Text TIONS.Text = RST13(4) R ST13(4) TXTDOCUMENTSENCLOSED.Text = RST13(5) TXTFEEDETAILS.Text = RST13(6) TXTPOLICECONFIRMATION.Text = RST13(7) TXTPREVIOUSAPPLIED.Text = RST13(8) TXTPASSPORTWRITING.Text TXTPASSPORTWRITING.Text = RST13(9) RST 13(9) TXTDISPATCH.Text TXTDISPATCH.Text = RST13(10) End Sub FEE PARTICULARS PARTICULARS FORM Option Explicit Dim DB As Database Dim RST9 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST9(0) LSTMODEOFPAYMENT.Text = RST9(1) TXTAMOUNT.T TXTAMOUNT.Text ext = RST9(2) RS T9(2) 63
LSTVALID.Text LSTVALID.Text = RST9(3) End Sub Private Sub FILLDB() RST9(0) = TXTFILENO.Text RST9(1) = LSTMODEOFPAYMENT.Text RST9(2) = TXT T XTAMOUNT.T AMOUNT.Text ext RST9(3) = LSTV LS TVALID.Text ALID.Text End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or LSTMODEOFPAYMENT.Text = "" Or TXTAMOUNT.Text = "" Or LSTVALID.Text = "" Or LSTVALID.Text = "N") Then MsgBox "U CAN'T SAVE THE FORM" Unload Me ADMINISTRATIVEVERIFICATION.Show Else RST9.MoveFirst While RST9.EOF <> True If RST9(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST9.MoveNext Wend RST9.AddNew FILLDB 64
RST9.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(6) = "YES" RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(6) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me ADMINISTRATIVEVERIFICATION.Show End If HEAVEN: Unload Me 65
ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command8 TXTFILENO.Text DataReport8.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = ADMINISTRATIVEVERIF ADMINISTRATIVEVERIFICA ICATION.TXT TION.TXTFILENO.Text FILENO.Text Set RST9 = DB.OpenRecordset("FEEPARTICULARS") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") End Sub Private Sub CMDEXIT_Click() Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST9.MoveFirst FILLFORM 66
End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED RST9.MoveLast FILLFORM End Sub
Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST9.MoveNext If RST9.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST9.MovePrevious If RST9.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub 67
Private Sub CLEARED() TXTFILENO.Text = "" LSTMODEOFPAYMENT.Text = "" TXTAMOUNT.Text = "" LSTVALID.Text = "" End Sub REPORTS FORM
Private Sub CMDreport_Click() CMDreport_Click() Dim A, B As Date If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open A = Format$(TXTDATE1.Text, "d/mmm/yyyy") B = Format$(Date$, Format$(Date$, "d/mmm/yyyy") DataEnvironment1.Command1 DataEnvironment1.Command1 A, B DataReport2.Show End Sub Private Sub Command2_Click() Command2_Click() Unload Me PASSPORTAUTHORITY.Show End Sub Private Sub Form_Load() TXTDATE2.Text TXTDATE2.Text = Date End Sub PASSPORT AUTHORITY FORM Private Sub CMDADMIN_Click(Index CMDADMIN_Click(Index As Integer) 68
ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub CMDBACK_Click() MAINMENU.Show End Sub Private Sub CMDCONFIRMATION_Click(Index As Integer) CONFIRMATIONDETAILS.Show End Sub
Private Sub CMDENQUIRY_Click(Index As Integer) ENQUIRYDETAILS.Show End Sub Private Sub CMDEXISTING_Click(Index CMDEXISTING_Click(Index As Integer) DETAILSOFAPPLICANT.Show End Sub Private Sub CMDEXIT_Click() End End Sub Private Sub CMDNEWPASSPORT_Click(Index As Integer) APPLICATIONFORM.Show End Sub Private Sub CMDreport_Click(Index CMDreport_Click(Index As Integer) Load Form1 Form1.Show End Sub PASSPORT WRITING Option Explicit 69
Dim DB As Database Dim RST10 As Recordset Dim RST1 As Recordset Dim RST2 As Recordset Dim RST8 As Recordset Dim RST13 As Recordset Dim RST As Recordset
Private Sub FILLDB() RST10(0) = TXTFILENO.Text RST10(1) = TXTAPPLICANTNAME.Text RST10(2) = TXTNATIONALITY.Text RST10(3) = LSTSEX.Text RST10(4) = TXTDOB.Text RST10(5) = TXTPLACEOFBIRTH.Text RST10(6) = TXTDATEOFISSUE.Text RST10(7) = TXTDATEOFEXPIRY.Text RST10(8) = TXTF T XTFA ATHERNAME.T THERNAME .Text ext RST10(9) = TXTMOTHERNAME.Text RST10(10) = TXTSPOUSENAME.Text RST10(11) = TXTADDRESS. TXTADDRESS.T Text RST10(12) = Text1.Text Text1.Text RST10(13) = Text2.Text Text2.Text RST10(14) = Text3.Text Text3.Text RST10(15) = LSTEMMIGRATIONCHECK.Text RST10(16) = TXTP TXT PASSPORTNO.Text ASSPORTNO.Text End Sub 70
Private Sub CMDSAVE_Click() RST10.AddNew FILLDB RST10.Update MsgBox "RECORD IS SAVED" RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(9) = "YES" RST13.Update Else End If RST13.MoveNext Wend Load DISPATCHDETAILS DISPATCHDETAILS.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command9 TXTFILENO.Text DataReport9.Show End Sub Private Sub Form_Load() Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") 71
Set RST10 = DB.OpenRecordset("PASSPORTWRITING") Set RST1 = DB.OpenRecordset("PERSONALINFORMATION") Set RST2 = DB.OpenRecordset("ADDRESSDETAILS") Set RST8 = DB.OpenRecordset("EMMIGRATIONCHECK") Set RST13 = DB.OpenRecordset("ENQUIRY") Set RST = DB.OpenRecordset("APPLICATION") TXTFILENO.Text = CONFIRMATIONDETAILS.TXTFILENO.Text RST1.MoveFirst While RST1.EOF <> True If RST1(0) = TXTFILENO.Text Then TXTAPPLICANTNAME.Text = RST1(1) TXTNATIONALITY.Text = RST1(9) LSTSEX.Text = RST1(6) TXTDOB.Text = RST1(7) TXTPLACEOFBIRTH.Text = RST1(5) TXTFATHERNAME TXTFATHERNAME.T .Text ext = RST1(2) RS T1(2) TXTMOTHERNAME.Text = RST1(3) TXTSPOUSENAME.Text = RST1(4) Else End If RST1.MoveNext Wend TXTDATEOFISSUE.Text = Date TXTDATEOFEXPIRY TXTDATEOFEXPIRY.Text .Text = DateAdd("YYYY" Date Add("YYYY",, 10, Date) RST2.MoveFirst While RST2.EOF <> True If RST2(0) = TXTFILENO.Text Then 72
TXTADDRESS.Text = RST2(1) Text1.Text = RST2(2) Text2.Text = RST2(3) Text3.Text = RST2(4) Else End If RST2.MoveNext Wend
RST8.MoveFirst While RST8.EOF <> True If RST8(0) = TXTFILENO.Text Then If (RST8(1) = "Y" Or RST8(2) = "Y" Or RST8(3) = "Y" Or RST8(4) = "Y" Or RST8(5) = "Y") Then LSTEMMIGRATIONCHECK.Text = "NOT REQUIRED" Else LSTEMMIGRATIONCHECK.Text = "REQUIRED" End If Else End If RST8.MoveNext Wend RST.MoveFirst While RST.EOF <> True If RST(11) = TXTFILENO.Text Then If RST(1) = "FRESHPASSPORT" Then 73
MsgBox "PLEASE ISSUE NEW PASSPORT NUMBER TO FRESHER" Else TXTPASSPORTNO.T TXTPASSPORTNO.Text ext = RST(12) RS T(12) End If End If RST.MoveNext Wend End Sub
PERSONAL INFORMATION FORM Option Explicit Dim DB As Database Dim RST As Recordset Dim RST1 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST1(0) TXTAPPLICANTNAME.Text = RST1(1) TXTFATHERNAME. TXTFATHERNAME.T Text = RST1(2) RS T1(2) TXTMOTHERNAME.Text = RST1(3) TXTSPOUSENAME.Text = RST1(4) TXTPLACEOFBIRTH.Text = RST1(5) LSTSEX.Text = RST1(6) TXTDOB.Text = RST1(7) TXTAGE.Text = RST1(8) 74
TXTNATIONALITY.Text = RST1(9) End Sub Private Sub FILLDB() RST1(0) = TXTFILENO.Text RST1(1) = TXTAPPLICANTNAME.Text RST1(2) = TXTF T XTFA ATHERNAME.Text THERNAM E.Text RST1(3) = TXTMOTHERNAME.Text RST1(4) = TXTSPOUSENAME.Text RST1(5) = TXTPLACEOFBIRTH.Text RST1(6) = LSTSEX.Text RST1(7) = TXTDOB.Text RST1(8) = TXTAGE.Text TXTAGE.Text RST1(9) = TXTNATIONALITY.Text End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or TXTAPPLICANTNAME.Text = "" Or TXTFATHERNAME.Text = "" Or TXTMOTHERNAME.Text = "" Or TXTSPOUSENAME.Text = "" Or TXTPLACEOFBIRTH.Text = "" Or LSTSEX.Text = "" Or TXTDOB.Text = "" Or TXTAGE.Text = "" Or TXTNATIONALITY.Text = "") Then MsgBox "U CANT SAVE THE FORM" Unload Me DETAILSOFAPPLICANT.Show Else RST1.MoveFirst While RST1.EOF <> True If RST1(0) = TXTFILENO.Text Then 75
MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST1.MoveNext Wend RST1.AddNew FILLDB RST1.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(1) = "YES" RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(1) = "YES" RST13.Update Else 76
End If RST13.MoveNext Wend Unload Me DETAILSOFAPPLICANT.Show End If HEAVEN: Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command2 TXTFILENO.Text DataReport1.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = DET DE TAILSOFAPPLICANT.TXTFILE AILSOFAPPLICANT.TXTFILENO.Text NO.Text Set RST1 = DB.OpenRecordset("PERSONALINFORMATION") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") Set RST = DB.OpenRecordset("APPLICATION") RST.MoveFirst 77
While RST.EOF <> True If RST(11) = TXTFILENO.Text Then TXTFILENO.Enabled TXTFILENO.Enabled = False TXTAPPLICANTNAME.Text = RST(2) TXTPLACEOFBIRTH.Text = RST(3) LSTSEX.Text = RST(7) TXTDOB.Text = RST(4) TXTAGE.Text = RST(5) TXTNATIONALITY.Text = RST(6) Else End If RST.MoveNext Wend End Sub Private Sub CMDEXIT_Click() Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST1.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED 78
RST1.MoveLast FILLFORM End Sub Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST1.MoveNext If RST1.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST1.MovePrevious If RST1.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" TXTAPPLICANTNAME.Text = "" TXTFATHERNAME.Text = "" TXTMOTHERNAME.Text = "" 79
TXTSPOUSENAME.Text = "" TXTPLACEOFBIRTH.Text = "" LSTSEX.Text = "" TXTDOB.Text = "" TXTAGE.Text TXTAGE.Text = "" "" TXTNATIONALITY.Text = "" End Sub PHYSICAL PARTICULARS PARTICULARS FORM Option Explicit Dim DB As Database Dim RST As Recordset Dim RST3 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST3(0) TXTHEIGHT.Text = RST3(1) TXTWEIGHT.Text = RST3(2) TXTCOLOROFEYES.Text = RST3(3) TXTCOLOROFHAIR.Text = RST3(4) TXTIDENTIFICATIONMARKS.Text = RST3(5) End Sub Private Sub FILLDB() RST3(0) = TXTFILENO.Text RST3(1) = TXTHEIGHT.Text RST3(2) = TXTWEIGHT.Text RST3(3) = TXTCOLOROFEYES.Text 80
RST3(4) = TXTCOLOROFHAIR.Text RST3(5) = TXTIDENTIFICATIONMARKS.Text End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or TXTHEIGHT.Text = "" Or TXTWEIGHT.Text = "" Or TXTCOLOROFEYES.Text = "" Or TXTCOLOROFHAIR.Text = "" Or TXTIDENTIFICATIONMARKS.Text = "") Then MsgBox "U CANT SAVE THE FORM" Unload Me DETAILSOFAPPLICANT.Show Else RST3.MoveFirst While RST3.EOF <> True If RST3(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST3.MoveNext Wend RST3.AddNew FILLDB RST3.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then 81
RST14.Edit RST14(3) = "YES" RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(3) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me DETAILSOFAPPLICANT.Show End If HEAVEN: Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close 82
DataEnvironment1.Connection1.Open DataEnvironment1.Command4 TXTFILENO.Text DataReport4.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = DET DE TAILSOFAPPLICANT.TXTFILE AILSOFAPPLICANT.TXTFILENO.Text NO.Text Set RST3 = DB.OpenRecordset("PHYSICALPARTICULARS") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") Set RST = DB.OpenRecordset("APPLICATION") End Sub Private Sub CMDEXIT_Click() Unload Me DETAILSOFAPPLICANT.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST3.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED 83
RST3.MoveLast FILLFORM End Sub Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST3.MoveNext If RST3.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST3.MovePrevious If RST3.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" TXTHEIGHT.Text = "" TXTWEIGHT.Text = "" TXTCOLOROFEYES.Text = "" 84
TXTCOLOROFHAIR.Text = "" TXTIDENTIFICATIONMARKS.Text = "" End Sub POLICE RECORDS FORM Option Explicit Dim DB As Database Dim RST7 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset
Private Sub FILLFORM() TXTFILENO.Text = RST7(0) LSTCONVICTED.Text = RST7(1) End Sub Private Sub FILLDB() RST7(0) = TXTFILENO.Text RST7(1) = LSTCONVICTED.Text End Sub Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or LSTCONVICTED.Text = "" Or LSTCONVICTED.Text = "Y") Then MsgBox "U CANT SAVE THE FORM" Unload Me ADMINISTRATIVEVERIFICATION.Show Else RST7.MoveFirst While RST7.EOF <> True 85
If RST7(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST7.MoveNext Wend RST7.AddNew FILLDB RST7.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(7) = "YES" RST14.Update Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(7) = "YES" RST13.Update 86
Else End If RST13.MoveNext Wend Unload Me ADMINISTRATIVEVERIFICATION.Show End If HEAVEN: Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command7 TXTFILENO.Text DataReport7.Show End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = ADMINISTRATIVEVERIF ADMINISTRATIVEVERIFICA ICATION.TXT TION.TXTFILENO.Text FILENO.Text Set RST7 = DB.OpenRecordset("POLICERECORDS") DB.OpenRecordset("POLICERECORDS") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") End Sub 87
Private Sub CMDEXIT_Click() Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST7.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED RST7.MoveLast FILLFORM End Sub Private Sub CMDNEXT_Click() CMDSUBMIT.Enabled = False RST7.MoveNext If RST7.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False 88
CLEARED RST7.MovePrevious If RST7.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub
Private Sub CLEARED() TXTFILENO.Text = "" LSTCONVICTED.Text = "" End Sub PREVIOUS APPLIED APPLIED FORM Option Explicit Dim DB As Database Dim RST6 As Recordset Dim RST14 As Recordset Dim RST13 As Recordset Private Sub FILLFORM() TXTFILENO.Text = RST6(0) LSTAPPLIED.Text = RST6(1) End Sub Private Sub FILLDB() RST6(0) = TXTFILENO.Text RST6(1) = LSTAPPLIED.Text End Sub 89
Private Sub CMDSUBMIT_Click() CMDSUBMIT_Click() If (TXTFILENO.Text = "" Or LSTAPPLIED.Text = "" Or LSTAPPLIED.Text = "Y") Then MsgBox "U CANT SAVE THE FORM" Unload Me ADMINISTRATIVEVERIFICATION.Show Else RST6.MoveFirst While RST6.EOF <> True If RST6(0) = TXTFILENO.Text Then MsgBox "THIS RECORD ALREADY EXISTS" EXISTS" GoTo HEAVEN Else End If RST6.MoveNext Wend RST6.AddNew FILLDB RST6.Update MsgBox "RECORD SAVED" RST14.MoveFirst While RST14.EOF <> True If RST14(0) = TXTFILENO.Text Then RST14.Edit RST14(8) = "YES" RST14.Update 90
Else End If RST14.MoveNext Wend RST13.MoveFirst While RST13.EOF <> True If RST13(0) = TXTFILENO.Text Then RST13.Edit RST13(8) = "YES" RST13.Update Else End If RST13.MoveNext Wend Unload Me ADMINISTRATIVEVERIFICATION.Show End If HEAVEN: Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub Command1_Click() Command1_Click() If DataEnvironment1.Connection1.State DataEnvironment1.Connection1.State = 1 Then DataEnvironment1.Connection1.Close DataEnvironment1.Connection1.Open DataEnvironment1.Command6 TXTFILENO.Text DataReport6.Show 91
End Sub Private Sub Form_Load() CMDSUBMIT.Enabled = True CMDEXIT.Enabled = True Set DB = OpenDatabase(App.Path & "\PASSPORT.MDB") TXTFILENO.Text TXTFILENO. Text = ADMINISTRATIVEVERIF ADMINISTRATIVEVERIFICA ICATION.TXT TION.TXTFILENO.Text FILENO.Text Set RST6 = DB.OpenRecordset("PREVIOUSAPPLIED") DB.OpenRecordset("PREVIOUSAPPLIED") Set RST14 = DB.OpenRecordset("CONFIRMATION") Set RST13 = DB.OpenRecordset("ENQUIRY") End Sub Private Sub CMDEXIT_Click() Unload Me ADMINISTRATIVEVERIFICATION.Show End Sub Private Sub CMDFIRST_Click() CMDSUBMIT.Enabled = False CLEARED RST6.MoveFirst FILLFORM End Sub Private Sub CMDLAST_Click() CMDSUBMIT.Enabled = False CLEARED RST6.MoveLast FILLFORM End Sub Private Sub CMDNEXT_Click() 92
CMDSUBMIT.Enabled = False RST6.MoveNext If RST6.EOF Then MsgBox "THIS IS THE LAST RECORD" Else FILLFORM End If End Sub Private Sub CMDPREV_Click() CMDPREV_Click() CMDSUBMIT.Enabled = False CLEARED RST6.MovePrevious If RST6.BOF Then MsgBox "THIS IS THE FIRST RECORD" Else FILLFORM End If End Sub Private Sub CLEARED() TXTFILENO.Text = "" LSTAPPLIED.Text LSTAPPLIED.Text = "" End Sub
93
SCREENS
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111 111
112
113
114
REPORTS
115
116
117
118
119
120
6. SYSTEM TESTING The common view of testing held by users is that it is performed to prove that there are no errors in a program. This is extremely difficult since designer cannot prove to be one hundred percent accurate. Therefore, the most useful useful and pract practica icall approa approach ch is with with the und unders erstan tandin ding g that that testing testing is the process of executing a program with explicit intention of finding errors that make the program fail.
Testing has its own cycle. The testing process begins with the product requirements phase and from there parallels the entire development process. In other words, for each phase of the development process there is an important testing activity. activity. Successful testing requires a methodical approach. It requires to focus on basic critical factors:
•
Planning
•
Project and process control
•
Risk management
•
Inspections
•
Measurement tools
•
Organization Organization and professionalism
121
Test plan:
Before going for testing, first we have to decide upon the type of testing to be carried out. The following factors are taken into consideration:
•
To ensure that information properly properly flows into and out of program
•
To find out whether the local data structures maintains its integrity during all steps in an algorithm execution
•
To ensure that the module operate properly at boundaries established to limit or restrict processing
•
To find out whether error - handling paths are working correctly or not
•
To find out whether the values are correctly updated or not
•
Check for validations
Unit Testing:
Unit or module testing is the process of testing the individual components (subprograms (subprograms or procedures) of a program. The purpose is to discover discrepancies between the modules interface specification and its actual behaviour. behaviour. In our system each module namely (i) search search module module (ii) request module (iii) order module must be tested independently for validation.
122
Integration Testing:
Integration testing is the process of combining and testing multiple components together. together. The primary objective of o f integration testing is to discover errors in the interfaces between the components. In our system each of the modules mentioned above, are tested for checking the integration between them, after each of them are tested Individually.
System Testing:
Validation testing provides the final assurance that software so ftware meets all functional, behavioral and performance requirement. The software s oftware once validated must be combined with other system elements. System testing verifies that as elements combine properly and that overall system function and performance is achieved.
123
7. CONCLUSION Computerization of PASSPORT MANAGEMENT SYSTEM does effectively reduce the manual work involved in generating passport to a citizen with unique passport number. number. It saves time and gives easy access for already stored information. It enables the ADMINISTRATOR in providing faster services to the applicants.
The system is completely menu driven and extremely user friendly since it is developed in an efficient front end tool Visual Basic . Appropriate error messages are also provided too guide the user in a proper and user friendly manner.
The system has effective management of records which holds all the information of a particular citizen. Even if all the details of the applicant are not sustained reports are generated and sent to the applicant. Finally, after passing all the confirmation requirements the passport is being written and is dispatched.
124
8. SCOPE OF ENHANCEMENT This application is designed to be generic. As we develop our site we should take advantage of several areas in which you can improve and easy for applicant. This project was developed an vb.6.0 with backend as ms-access.this project is fully fledged fledged and flexible flexible and further this project can be automated automated as the online passport management.On registering online we can get the issue of passport date. The system has effective transaction for taking the applicant details, passport information required for generation of a passport. It helps in generating reports on passport in specified format.
125
9. BIBILOGRAPHY BIBILOGRAPHY 1.
VISUAL BASIC 6 IN 21 DAYS BY
NATHAN NATHAN GUREWICH ORI GUREWICH 2. VISUAL BASIC 6.0 PROGRAMMING BIBLE
BY ERIC A.SMITH VALOR WHISTLER HENK MARQUIS 3.
MAST MASTER ERIN ING G VIS VISUA UAL L BASI BASIC C 6.0 6.0
BY EVANGELOS PETROUTSONS
4. VISUAL BASIC 6 FROM THE GROUND UP
BY GARY CORNELL 5. DAT DATABASE SYSTEM CONCEPTS
BY ABRAHAM HENRY. F. LORTH
126