Builder and Developer: Tilak College of Science & Commerce
Builder and Developer: Tilak College of Science & Commerce
PROJECT REPORT
ON
BY
UNIVERSITY OF MUMBAI
(2014 – 2015)
PROJECT GUIDE
1
Builder and Developer 2015
TABLE OF CONTENT
2. Introduction
3. Present system :
A. Present system
4 Proposed System:
A. Proposed System
B. Features
D. Feasibility Study
E. Gantt Chart
5. System Documentation :
A. Event Table
C. ER Diagram
D. Activity Diagram
E. Class Diagram
. F. Object Diagram
G. Sequence Diagram
6. System Design:
A. Converting ERD into Tables
B. Component Diagram
C. Package Diagram
D. Deployment Diagram
7. System Coding:
2
Builder and Developer 2015
B. Technology used
C. Menu Tree
D. Table Design
F. Program Description
G. Form Description
H. Validation
I. System Coding
9. Screen Layouts
10. Testing
12. Conclusion
3
Builder and Developer 2015
ACKNOWLEDGEMENT
4
Builder and Developer 2015
PRELIMINARY
INVESTIGATION
5
Builder and Developer 2015
INTRODUCTION
In old days, the Property Dealer may have to keep records of the
properties manually. This method of keeping the records is quiet time
consuming and less efficient. Also there are more chances of mistakes by
keeping the records manually as human beings are habitual of doing mistakes.
So with the help of this, Property Dealing Software, the chances of mistakes
becomes very few. Also it is very efficient method of keeping the records of
properties sold as well as unsold properties. It consumes very less time as
compared to manual method.
The application is divided into three modules. The admin i.e. the
Property Dealer itself handles the whole software . He managed the database
as well as all the records.
6
Builder and Developer 2015
There are several types of cost associated with manual records. One
type , duplication of the record, requires paper and copying supplies, as well
as the staff to create and distribute the copies. Staff hired to assemble, file,
retrieve, or distribute the hard copy chart is a costly expenses. Storage of the
paper record necessitates the use of valuable space that could be better
utilized. The records also need to be protected from water, fire, or
mishandling of the paper to preserve their physical integrity. Staff members
time required to deliver paper records to a specific location. If the paper
record is not readily available, clerical staff responsible for filling
documentation may need to make several attempts before the task is
completed. There is no ability to sort data fields in a paper record. Staff
responsible for reporting mandated data elements to the appropriate
organizations must perform a manual review. There is limitation to the
physical quality of the paper record. Paper is fragile and does not last
permanently. Normal use of the record may result in torn or stained
documents also over the years, ink used to complete documentation can fade.
Actual damage resulting from water or fire is another threat to the physical
integrity of the paper records.
Major Disadvantage:
• Accessibility of records
7
Builder and Developer 2015
PROPOSED SYSTEM
Features:
All the records and data have been computerized and are now
persistent.
Manual calculations have been automated.
Access to all types of records made easy.
The proposed system is a computerized system.
The customer has to just give his details like contact number, address,
Number of person accommodating with him and also the mode of
payment along with his details.
It also maintain record of all people who have visited their hotel, has a
stay before through a database.
Paper work is avoid.
8
Builder and Developer 2015
The system simplifies the work of searching and adding the details of
customer.
Formatted data.
Records/ information’s are easily approachable.
The calculation can be done automatically.
FEASIBILITY STUDY
Operational Feasibility:
9
Builder and Developer 2015
Economical Feasibility:
1. Development Cost
• Equipments required for developing the software are easily available.
• Equipment maintenance is also minimum.
• Saving of paper work and manpower reduced.
• Once the required hardware and software requirements get fulfilled
there is no need for the user of our system to spend for any additional
overhead.
• Training cost is reduced.
2. Benefits which cannot be measured:
• Increased customer Loyalty
• Increased customer satisfaction
Technical Feasibility:
Social feasibility:.
10
Builder and Developer 2015
GANTT CHART
1. Planning Phase
Define the problem
Work breakdown structure
Product Project Schedule
2. Analysis Phase
Gather Information
Define System Requirement
Objectives and Feasibility
3. Design Phase
Design Database
Design System
Flow
4. Coding Phase
Write Code for
Individual
11
Builder and Developer 2015
Component
Integrate the components
5. Testing Phase
Unit Testing
System Testing
Integration Testing
6. Implementation Phase
12
Sr. Phase Expected Actual Finish Remark
Date of Date
No. Completion
Attributes, Constraints
METHODOLOGY ADOPTED
At each stage of IM, a new build is coded and then integrated into the
structure which is tested as a whole. Note that the product is defined as
finished only when it satisfies all of its requirements.
This model combines the elements of Waterfall model with the iterative
philosophy of prototyping. However, unlike prototyping the IM focuses on
the delivery of an operational product at the end of each increment.
14
Builder and Developer 2015
The first increment is usually the core product which addresses the
basic requirements of the system. This may be either be used by the client or
subjected to detailed review to develop plan for the next increment.
Essentially the build with the highest value-to-cost ratio is the one that
provides the client with the most functionality (value) for the least cost. Using
this method, the client has a usable product at all of the development stages.
15
Builder and Developer 2015
SYSTEM ANALYSIS
16
Builder and Developer 2015
EVENTS
An event occurs at a specific time & place, that can be described & is worth
remembered by the system. Events drive or trigger all processing that a
system does, so listing them & then analyzing them make sense when you
need to define system requirements.
EXTERNAL EVENT:
An event that occurs outside the system usually initiated by an external
agent or actor.
TEMPORAL EVENT:
An event that occurs as a result of reaching a point in time.
EVENT TABLE
A table that lists events in rows & key pieces of information about
each event in columns.
TRIGGER:
An occurrence that tells the system that an event has occurred, either
the arrival of data needing processing or of point in time.
SOURCE:
An external agent or actor that supplies data to the system.
ACTIVITY:
Behavior that the system performs when an event occurs.
RESPONSE:
An output, produce by the system that goes to the system.
DESTINATION:
An external agent or actor that receives data from the system.
17
Builder and Developer 2015
EVENT TABLE
2. Builder adds Flat entry Builder Adds entry of Flat details Flat master
flat details flats
18
Builder and Developer 2015
USE CASE:
ACTOR:
CONNECTING LINE:
19
Builder and Developer 2015
Use Case
Automation Boundary
Connecting Line
Use Case
Actor
DESCRIPTION:
The Object Oriented approach uses the term use case to describe
an activity the system carries out in response to an event. One can think
of a use case as a case or situation where the system is used for some
purpose .A use case diagram is a convenient way to document the
functions that the system must support. Sometimes a single,
20
Builder and Developer 2015
bkjkkkncxkcc
Makes
enquiry
Gives details of
flats
Gives documents
of flat
21
Builder and Developer 2015
Entity:
Attributes:
Domain:
For each attribute associated with an entity set, we must identify a
domain of possible values. For e.g. the domain associated with the attribute
name of the student might be of the set of 20-character string. Another
example would be the ranking of the students in the institute would be on the
scale of 1-6, the associated domain consists of integers 1 through 6.
Key:
22
Builder and Developer 2015
Further, for each entity set we choose a key. A key is a minimal set of
attributed whose values uniquely identify an entity in the set. There could be
more than one candidate; if so we designate one of them as primary key. For
now we will assume that each entity set contains at least one set of attributes
that uniquely identify an entity in the entity set; that is the set of attributes
contains a key.
ENTITY SET
PROCESS
ER - DIAGRAM
23
Builder and Developer 2015
Address
Contact No
Address
Name
Name
Client
Address
Cancel_I Cancellation
Name D
Building
Flat
enquiry
Name
Name Off_Address
Builder Transact
Contact Booking
ion
balance Address
Rate
Area
Flat Flat
purchase Registration
* Pay ID
Customer
Name
Pay ID Registration ID
Booking ID
ACTIVITY DIAGRAM
24
Builder and Developer 2015
ACTIVITY DIAGRAM
Start
25
Login screen
Invalid Gives
an
error
Valid
Login successfully
Start
26
Client takes
information
Builder and Developer 2015
Developer gives
building info.
Booking
If Cancellation
intereste No
d
Yes
Report generation
27
Builder and Developer 2015
CLASS DIAGRAM
CLASS DIAGRAM:
RELATIONSHIP:
A naturally occurring association among specific things.
DESCRIPTION:
CLASS DIAGRAM
28
Builder and Developer 2015
Builder
Off Address
Contact No
Name
Make records of
building
* Flat
Type
Rate
Area
Add(),update()
Delete()
Building
Name * *
Location
Assign Share
Holder
Delete Share
*
Customer
Id
Name
Contact –No
RegId
Add(),update()
Delete()
1..*
*
29
Builder and Developer 2015
* *
Booking
Name
Booking id
Reg id
Add(),update()
Delete()
Payment
Payment Id
Booking Id
Add(),update()
Delete()
1…
*
OBJECT DIAGRAM
Object diagrams are derived from class diagrams so object diagrams are
dependent upon class diagrams.
Object diagrams represent an instance of a class diagram. The basic concepts
are similar for class diagrams and object diagrams. Object diagrams also
30
Builder and Developer 2015
represent the static view of a system but this static view is a snapshot of the
system at a particular moment.
So the purpose of the object diagram can be summarized as:
• Forward and reverse engineering.
Builder : B
1 * Building : Bl 1
Name = ”ABC”
Name=”Sai”
Flat : F
Flat ID=”101”
Customer : C
Cust ID = ”100”
Booking : BK Client : Cl
Cancellation : CA
Regi ID=”500"
31
Builder and Developer 2015
SEQUENCE DIAGRAM
32
Builder and Developer 2015
SEQUENCE DIAGRAM
Develops
building
Enquiry of flats
if not affordable
cancellation
33
Builder and Developer 2015
34
Builder and Developer 2015
Start
Developing Buildings
Taking information
If
intere
No
st
Yes
Booking Cancellation
Cancellation
generating bills
Gives Payment
35
Builder and Developer 2015
SYSTEM DESIGN
36
Builder and Developer 2015
Parts are:
Entity Sets.
Relationship Sets.
We will convert each entity set to table, which involves deciding the tables.
37
Builder and Developer 2015
Builder
Building
Customer
Pay ID Name Address Contact No Registration Booking
ID ID
Flat
Id Area Rate Flat type
Booking
Book ID Name Address
Payment
Pay ID Book ID
Cancellation
Cancel ID Client ID Refund
38
Builder and Developer 2015
COMPONENT DIAGRAM
Component Diagrams:
39
Builder and Developer 2015
COMPONENT DIAGRAM
Flat Master
MDI
Enquiry
Registration
Master
Booking
Master
40
Builder and Developer 2015
PACKAGE DIAGRAM
package import
package merge
Package diagrams can use packages that represent the different layers
of a software system to illustrate the layered architecture of a software
system. The dependencies between these packages can be adorned with labels
stereotypes to indicate the communication mechanism between the layers.
41
Builder and Developer 2015
PACKAGE DIAGRAM
Builder_Developer
Builder Building
Customer Client
Payment
Booking
42
DEPLOYMENT DIAGRAM
The nodes appear as boxes, and the artifacts allocated to each node
appear as rectangles within the boxes. Nodes may have sub nodes, which
appear as nested boxes. A single node in a deployment diagram may
conceptually represent multiple physical nodes, such as a cluster of database
servers.
Hardware
Builder_Developer
43
Database
Builder and Developer 2015
SYSTEM CODING
44
Builder and Developer 2015
HARDWARE REQUIREMENTS:
1. PROCESSOR: Pentium 3 or higher
2. RAM: 512 MB or higher
3. HARD DISK SPACE: 80GB or higher
SOFTWARE REQUIREMENTS:
1. FRAMEWORK: Net Framework 4.0
2. ENVIRONMENT: MICROSOFT VISUAL STUDIO.NET
3. DATABASE: SQL SERVER.
4. PLATFORM: Windows
45
Builder and Developer 2015
Technology Used
Like all other .NET languages, VB.NET has complete support for object-
oriented concepts. Everything in VB.NET is an object, including all of the
primitive types (Short, Integer, Long, String, Boolean, etc.) and user-defined
types, events, and even assemblies. All objects inherits from the base class
Object.
• Component oriented.
• Easy to learn.
• Structured language.
47
Builder and Developer 2015
To fully interact with other objects regardless of the language they were
implemented in, objects must expose to callers only those features that are
common to all the languages they must interoperate with. For this reason, the
Common Language Specification (CLS), which is a set of basic language
features needed by many applications, has been defined.
48
Builder and Developer 2015
MENU TREE
MASTER
• Buildings Details
• Flat Details
• Customer Details
• Enquiry Registration Details
• Booking Details
TRANSACTION
• Payment Transaction
• Registration Transaction
• Cancellation Transaction.
REPORTS
• Flat Report
• Payment Report
49
Builder and Developer 2015
TABLE DESIGN
LOGIN TABLE:-
Field Name Datatype Description
A) MASTERS:-
50
Builder and Developer 2015
51
Builder and Developer 2015
B) TRANSACTION:-
52
Builder and Developer 2015
53
Builder and Developer 2015
54
Builder and Developer 2015
PROGRAM DESCRIPTION
55
Builder and Developer 2015
This subsystem consists of handling all the work associated with respect to
customer.
This includes:
-Maintaining records of customer,
-Time to time updating their records.
56
Builder and Developer 2015
Saving Report
Account Report
Loan Report
Loan Payment Slip
Regular Payment Slip
FORM DESCRIPTION
Login:
Building:
57
Builder and Developer 2015
Customer:
Flat:
Booking:
59
Builder and Developer 2015
Payment:
Booking Cancellation:
60
Builder and Developer 2015
Registration:
61
Builder and Developer 2015
Validation
Login:
Customer Details:
62
Builder and Developer 2015
Payment Details:
Cancellation Details:
CODING
frmsplash.vb
Public Class frmsplash
Dim a As Integer = 0
Private Sub frmsplash_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Timer1.Enabled = True
End Sub
64
Builder and Developer 2015
End If
If ProgressBar1.Value = 100 Then
lblcount.Text = "100%"
Timer1.Stop()
a=0
Timer1.Enabled = False
Dim m As New frmmdi
m.Show()
Me.Hide()
End If
End Sub
End Class
frmlogin.vb
Imports System.Data.SqlClient
Public Class login
Dim n As Integer = 0
Dim con As New SqlConnection("Data Source=BSC-13\SQLEXPRESS;
Initial Catalog=bookingdatabase;Integrated Security=True")
Dim cmd As SqlCommand
Dim dr As SqlDataReader
Private Sub btnlogin_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnlogin.Click
Try
If con.State = ConnectionState.Closed Then
con.Open()
End If
cmd = New SqlCommand("select * from tbllogin", con)
dr = cmd.ExecuteReader()
While dr.Read
If dr(0).ToString() = txtusername.Text And dr(1).ToString() = txtpassword.Text Then
MsgBox("You have Login Successfully...")
frmsplash.Show()
Me.Hide()
Exit Sub
Else
MsgBox("Login denied...Please Try Again")
n=n+1
txtusername.Text = ""
txtpassword.Text = ""
txtusername.Focus()
End If
If n = 3 Then
MsgBox("Better try next time...")
End If
End While
con.Close()
Catch ex As Exception
65
Builder and Developer 2015
MsgBox(ex.ToString)
End Try
Me.Show()
End Sub
Private Sub btncancel_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btncancel.Click
Me.Close()
End Sub
Private Sub btnreset_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnreset.Click
txtusername.Text = ""
txtpassword.Text = ""
txtusername.Focus()
End Sub
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
Me.Hide()
frmchangrpwd.Show()
End Sub
End Class
frmmdi.vb
Imports System.Windows.Forms
Public Class frmmdi
Private Sub BuildingToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles BuildingToolStripMenuItem.Click
frmbuilding_details.MdiParent = Me
frmbuilding_details.Show()
End Sub
Private Sub CustomerToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles CustomerToolStripMenuItem.Click
frmcustomer.MdiParent = Me
frmcustomer.Show()
End Sub
Private Sub FlatToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles FlatToolStripMenuItem.Click
frmflat_details.MdiParent = Me
frmflat_details.Show()
End Sub
Private Sub EnquiryRegistrationToolStripMenuItem_Click(ByVal sender
As System.Object, ByVal e As System.EventArgs)
Handles EnquiryRegistrationToolStripMenuItem.Click
frmenq_registration.MdiParent = Me
frmenq_registration.Show()
End Sub
Private Sub BookingToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles BookingToolStripMenuItem.Click
frmbooking_info.MdiParent = Me
66
Builder and Developer 2015
frmbooking_info.Show()
End Sub
Private Sub PaymentToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles PaymentToolStripMenuItem.Click
frmpayment.MdiParent = Me
frmpayment.Show()
End Sub
Private Sub BookingCancellationToolStripMenuItem_Click(ByVal sender
As System.Object, ByVal e As System.EventArgs)
Handles BookingCancellationToolStripMenuItem.Click
frmbooking_cancellation.MdiParent = Me
frmbooking_cancellation.Show()
End Sub
Private Sub RegistrationToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles RegistrationToolStripMenuItem.Click
frmregistration.MdiParent = Me
frmregistration.Show()
End Sub
Private Sub PaymentToolStripMenuItem1_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles PaymentToolStripMenuItem1.Click
ReportPayment.MdiParent = Me
ReportPayment.Show()
End Sub
Private Sub BookingInformationToolStripMenuItem_Click(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
BookingInformationToolStripMenuItem.Click
rptBooking.MdiParent = Me
rptBooking.Show()
End Sub
Private Sub BookingCancellationToolStripMenuItem1_Click(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
BookingCancellationToolStripMenuItem1.Click
ReportBookCancellation.MdiParent = Me
ReportBookCancellation.Show()
End Sub
Private Sub FlatInformationToolStripMenuItem_Click(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles FlatInformationToolStripMenuItem.Click
rptflat.MdiParent = Me
rptflat.Show()
End Sub
Private Sub RegistrationInformationToolStripMenuItem_Click(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
RegistrationInformationToolStripMenuItem.Click
rptRegistration.MdiParent = Me
rptRegistration.Show()
End Sub
End Class
67
Builder and Developer 2015
Module1.vb
Imports System.Data.SqlClient
Module Module1
Public con As SqlConnection
Public Sub connection()
Source=D:\UMFH12\14642\library\database\library.mdb")
con = New SqlConnection("Data Source=BSC-13\SQLEXPRESS;
Initial Catalog=bookingdatabase;Integrated Security=True")
End Sub
Public Function chkChar(ByVal a As Integer) As Integer
If a >= 97 And a <= 123 Or a >= 65 And a <= 90 Or a = 8 Then
Return a
Else
Return 0
End If
End Function
Public Function chkInt(ByVal a As Integer) As Integer
If a >= 48 And a <= 57 Or a = 8 Then
Return a
Else
Return 0
End If
End Function
Public Function chkSpChar(ByVal a As Integer) As Integer
If a >= 97 And a <= 123 Or a >= 65 And a <= 90 Or a >= 48 And a <= 57 Or a = 8 Or
a = 32 Or a = 45 Or a = 44 Or a = 40 Or a = 41 Then
Return a
Else
Return 0
End If
End Function
Public Function chkCharInt(ByVal a As Integer) As Integer
If a >= 97 And a <= 123 Or a >= 65 And a <= 90 Or a >= 48 And a <= 57 Or a = 8 Then
Return a
Else
Return 0
End If
End Function
End Module
frmcustomer_details.vb
Imports System.Data.SqlClient
Public Class frmcustomer
68
Builder and Developer 2015
Catch ex As Exception
MsgBox(ex.ToString)
End Try
End Sub
Private Sub setFields(ByVal value As Boolean)
btnadd.Enabled = value
btnUpdate.Enabled = value
btnDelete.Enabled = value
btnExit.Enabled = value
btnclear.Enabled = value
End Sub
Private Sub setTextfields(ByVal value As Boolean)
txtname.Enabled = value
txtage.Enabled = value
txtprofession.Enabled = value
txtaincome.Enabled = value
txtcon_no.Enabled = value
txtoffadd.Enabled = value
End Sub
Private Sub clearFields()
txtid.Text = ""
txtname.Text = ""
txtoffadd.Text = ""
txtcon_no.Text = ""
txtprofession.Text = ""
txtage.Text = ""
txtaincome.Text = ""
End Sub
Private Sub BindFields()
txtid.DataBindings.Clear()
69
Builder and Developer 2015
txtname.DataBindings.Clear()
txtoffadd.DataBindings.Clear()
txtcon_no.DataBindings.Clear()
txtage.DataBindings.Clear()
txtprofession.DataBindings.Clear()
txtaincome.DataBindings.Clear()
txtid.DataBindings.Add("text", dv, "Cust_ID")
txtname.DataBindings.Add("text", dv, "Cust_Name")
txtoffadd.DataBindings.Add("text", dv, "Off_Address")
txtcon_no.DataBindings.Add("text", dv, "ContactNo")
txtprofession.DataBindings.Add("text", dv, "Profession")
txtage.DataBindings.Add("text", dv, "Age")
txtaincome.DataBindings.Add("text", dv, "Anu_Income")
End Sub
Private Sub setInfotoform()
Call setCon("Select * from customer_details")
BindFields()
Me.BindingContext(dv).Position = 0
End Sub
Private Function key_autogenerate()
Me.BindingContext(dv).Position = Me.BindingContext(dv).Count - 1
Return CInt(Me.BindingContext(dv).Current("Cust_ID") + 1)
End Function
Public Sub data()
Try
If Module1.con.State = ConnectionState.Closed Then
Module1.con.Open()
End If
Dim str As String = "select * from customer_details"
Dim cmd As New SqlCommand(str, Module1.con)
Dim p As New SqlDataAdapter(cmd)
Dim ds1 As New DataSet
p.Fill(ds1)
dgv.DataSource = ds1.Tables(0)
dgv.Update()
dgv.Refresh()
Module1.con.Close()
Catch ex As Exception
MsgBox(ex.ToString())
End Try
End Sub
Private Sub customer_Load(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles MyBase.Load
Call setInfotoform()
setTextfields(False)
Call data()
End Sub
Private Sub btnadd_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnadd.Click
70
Builder and Developer 2015
71
Builder and Developer 2015
txtcon_no.Text & ",'" & txtprofession.Text & " '," & txtage.Text & "," & txtaincome.Text
& ")"
i = cmd.ExecuteNonQuery
MsgBox(i & "record inserted")
Module1.con.Close()
Call data()
setFields(True)
setTextfields(False)
End If
Catch ex As Exception
MsgBox(ex.ToString)
End Try
End If
End Sub
Private Sub btnDelete_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnDelete.Click
Try
Module1.con.Open()
cmd = New SqlCommand
cmd.Connection = Module1.con
cmd.CommandText = "Delete from customer_details where
Cust_ID=" & txtid.Text & ""
i = cmd.ExecuteNonQuery()
MsgBox(i & "Record Deleted")
Module1.con.Close()
Call data()
setFields(True)
Catch ex As Exception
MsgBox(ex.ToString())
End Try
End Sub
Private Sub btnUpdate_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnUpdate.Click
If btnUpdate.Text = "Edit" Then
Call setFields(False)
btnUpdate.Enabled = True
btnExit.Enabled = True
btnUpdate.Text = "Update"
btnExit.Text = "Cancel"
setTextfields(True)
ElseIf btnUpdate.Text = "Update" Then
btnUpdate.Text = "Edit"
btnExit.Text = "Exit"
Try
Module1.con.Open()
cmd = New SqlCommand
cmd.Connection = Module1.con
cmd.CommandText = "update customer_details set Cust_Name='" &
txtname.Text & "',Off_Address='" & txtoffadd.Text & "',ContactNo =" & txtcon_no.Text
72
Builder and Developer 2015
& ",Profession ='" & txtprofession.Text & "',Age =" & txtage.Text & ",Anu_Income =" &
txtaincome.Text & " where Cust_ID=" & txtid.Text & ""
i = cmd.ExecuteNonQuery
MsgBox(i & "Record Updated")
Module1.con.Close()
Call data()
setFields(True)
setTextfields(False)
Catch ex As Exception
MsgBox(ex.ToString())
End Try
End If
End Sub
Private Sub btnExit_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnExit.Click
If btnExit.Text = "Exit" Then
End
ElseIf btnExit.Text = "Cancel" Then
btnadd.Text = "Add"
btnExit.Text = "Exit"
clearFields()
setFields(True)
setTextfields(False)
End If
End Sub
Private Sub btnclear_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnclear.Click
clearFields()
End Sub
Private Sub txtname_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtname.KeyPress,
txtname.KeyPress
e.KeyChar = Chr(chkChar(Asc(e.KeyChar)))
End Sub
Private Sub txtaddress_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtoffadd.KeyPress
e.KeyChar = Chr(chkChar(Asc(e.KeyChar)))
End Sub
Private Sub txtcon_no_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtcon_no.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub txtage_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtage.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub btnFirst_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnFirst.Click
Me.BindingContext(dv).Position = 0
73
Builder and Developer 2015
rowcount = 0
End Sub
Private Sub btnPrevious_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnPrevious.Click
rowcount = rowcount - 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position - 1
If rowcount < 0 Then
MsgBox("First Record")
rowcount = 0
End If
End Sub
Private Sub btnNext_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnNext.Click
rowcount = rowcount + 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position + 1
If rowcount = ds.Tables(0).Rows.Count Then
MsgBox("Last Record")
rowcount = rowcount - 1
End If
End Sub
Private Sub btnLast_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnLast.Click
BindFields()
Me.BindingContext(dv).Position = Me.BindingContext(dv).Count - 1
rowcount = ds.Tables(0).Rows.Count - 1
End Sub
Private Sub txtprofession_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtprofession.KeyPress
e.KeyChar = Chr(chkChar(Asc(e.KeyChar)))
End Sub
End Class
frmflat_Details.vb
Imports System.Data.SqlClient
Public Class frmflat_details
Dim con As SqlConnection
Dim cmd As SqlCommand
Dim da As SqlDataAdapter
Dim ds As DataSet
Dim dv As DataView
Dim dr As SqlDataReader
Dim rowcount As Integer = 0
Dim i As Integer
Dim flat_id As Integer
Private Sub setCon(ByRef strsql As String)
Try
con = New SqlConnection("Data Source=BSC-13\SQLEXPRESS;
74
Builder and Developer 2015
dr.Close()
Module1.con.Close()
Catch ex As Exception
End Try
End Sub
Private Sub btnadd_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnadd.Click
If btnadd.Text = "Add" Then
Call setFields(False)
btnadd.Enabled = True
btnExit.Enabled = True
btnadd.Text = "Save"
btnExit.Text = "Cancel"
flat_id = key_autogenerate()
Call clearFields()
setTextfields(True)
txtflat_id.Text = flat_id
ElseIf btnadd.Text = "Save" Then
Try
If txtbook_name.Text = "" And cmbwing.Text = "" And cmbflat_no.Text = ""
And cmbfloor.Text = "" And cmbtype_of_flat.Text = "" And txtarea.Text = "" And
txtrate.Text = "" And txttotal_amnt.Text = "" Then
MsgBox("Please fill all the fields")
ElseIf txtbook_name.Text = "" Then
MsgBox("Please enter booking name")
txtbook_name.Focus()
ElseIf cmbwing.Text = "" Then
MsgBox("Please enter the correct wing name")
cmbwing.Focus()
ElseIf cmbflat_no.Text = "" Then
MsgBox("Please enter flat no according you")
cmbflat_no.Focus()
ElseIf cmbfloor.Text = "" Then
MsgBox("Please enter the floor no.")
cmbfloor.Focus()
ElseIf cmbtype_of_flat.Text = "" Then
MsgBox("Please enter the type of flat according to you")
cmbtype_of_flat.Focus()
ElseIf txtarea.Text = "" Then
MsgBox("Please enter area")
txtarea.Focus()
ElseIf txtrate.Text = "" Then
MsgBox("Please enter rate of flat")
ElseIf txttotal_amnt.Text = "" Then
MsgBox("Please enter total amount of flat")
Else
btnadd.Text = "Add"
btnExit.Text = "Exit"
Module1.con.Open()
77
Builder and Developer 2015
btnExit.Text = "Exit"
Try
Module1.con.Open()
cmd = New SqlCommand
cmd.Connection = Module1.con
cmd.CommandText = "update tblflat_details set Booking_Name= '" &
txtbook_name.Text & "',Wing ='" & cmbwing.Text & "',Flat_No =" & cmbflat_no.Text &
",Floor ='" & cmbfloor.Text & "',Type_Of_Flat ='" & cmbtype_of_flat.Text & "',Area=" &
txtarea.Text & ",Rate=" & txtrate.Text & ",Total_Amount=" & txttotal_amnt.Text & "
where Flat_ID=" & txtflat_id.Text & ""
i = cmd.ExecuteNonQuery
MsgBox(i & "Record Updated")
setFields(True)
setTextfields(False)
Catch ex As Exception
MsgBox(ex.ToString())
Module1.con.Close()
Call data()
End Try
End If
End Sub
Private Sub btnExit_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnExit.Click
If btnExit.Text = "Exit" Then
End
ElseIf btnExit.Text = "Cancel" Then
btnadd.Text = "Add"
btnExit.Text = "Exit"
clearFields()
setFields(True)
setTextfields(False)
End If
End Sub
Private Sub btnFirst_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs)
Me.BindingContext(dv).Position = 0
rowcount = 0
End Sub
Private Sub btnPrevious_Click_1(ByVal sender As System.Object, ByVal e
As System.EventArgs)
rowcount = rowcount - 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position - 1
If rowcount < 0 Then
MsgBox("First Record")
rowcount = 0
End If
End Sub
Private Sub btnNext_Click_1(ByVal sender As System.Object, ByVal e
As System.EventArgs)
79
Builder and Developer 2015
rowcount = rowcount + 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position + 1
If rowcount = ds.Tables(0).Rows.Count Then
MsgBox("Last Record")
rowcount = rowcount - 1
End If
End Sub
Private Sub btnLast_Click_1(ByVal sender As System.Object, ByVal e
As System.EventArgs)
Me.BindingContext(dv).Position = Me.BindingContext(dv).Count - 1
rowcount = ds.Tables(0).Rows.Count - 1
End Sub
Private Sub btnclear_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnclear.Click
clearFields()
End Sub
Private Sub btnsearch_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnsearch.Click
Try
con.Open()
cmd = New SqlCommand
cmd.Connection = con
cmd.CommandType = CommandType.Text
If cmbsearch.Text <> "" Then
cmd.CommandText = "select * from tblflat_details where Flat_ID="
& cmbsearch.Text & ""
dr = cmd.ExecuteReader()
dr.Read()
txtflat_id.Text = dr("Flat_ID")
txtbook_name.Text = dr("Booking_Name")
cmbwing.Text = dr("Wing")
cmbflat_no.Text = dr("Flat_No")
cmbfloor.Text = dr("Floor")
cmbtype_of_flat.Text = dr("Type_Of_Flat")
txtarea.Text = dr("Area")
txtrate.Text = dr("Rate")
txttotal_amnt.Text = dr("Total_Amount")
con.Close()
Else
MsgBox("Pls Enter the Id to be viewed")
End If
Catch ex As Exception
MsgBox(ex.ToString())
End Try
con.Close()
End Sub
Private Sub btnFirst_Click_1(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnFirst.Click
Me.BindingContext(dv).Position = 0
80
Builder and Developer 2015
rowcount = 0
End Sub
Private Sub btnPrevious_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnPrevious.Click
rowcount = rowcount - 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position - 1
If rowcount < 0 Then
MsgBox("First Record")
rowcount = 0
End If
End Sub
Private Sub btnNext_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnNext.Click
rowcount = rowcount + 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position + 1
If rowcount = ds.Tables(0).Rows.Count Then
MsgBox("Last Record")
rowcount = rowcount - 1
End If
End Sub
Private Sub btnLast_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnLast.Click
BindFields()
Me.BindingContext(dv).Position = Me.BindingContext(dv).Count - 1
rowcount = ds.Tables(0).Rows.Count - 1
End Sub
Private Sub txtflat_id_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtflat_id.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub txtrate_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtrate.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub txtarea_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtarea.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub txttotal_amnt_GotFocus(ByVal sender As Object, ByVal e
As System.EventArgs) Handles txttotal_amnt.GotFocus
txttotal_amnt.Text = CInt(txtarea.Text) + CInt(txtrate.Text)
txttotal_amnt.Focus()
End Sub
Private Sub txttotal_amnt_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txttotal_amnt.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub cmbwing_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles cmbwing.KeyPress
81
Builder and Developer 2015
e.KeyChar = Chr(chkChar(Asc(e.KeyChar)))
End Sub
Private Sub cmbflat_no_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles cmbflat_no.KeyPress
e.KeyChar = Chr(chkInt(Asc(e.KeyChar)))
End Sub
Private Sub cmbfloor_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles cmbfloor.KeyPress
e.KeyChar = Chr(chkChar(Asc(e.KeyChar)))
End Sub
Private Sub txtbook_name_KeyPress(ByVal sender As Object, ByVal e
As System.Windows.Forms.KeyPressEventArgs) Handles txtbook_name.KeyPress
e.KeyChar = Chr(chkChar(Asc(e.KeyChar)))
End Sub
End Class
frmpayment_details.vb
Imports System.Data.SqlClient
Public Class frmpayment
Dim con As SqlConnection
Dim cmd As SqlCommand
Dim da As SqlDataAdapter
Dim ds As DataSet
Dim dv As DataView
Dim dr As SqlDataReader
Dim dr1 As SqlDataReader
Dim rowcount As Integer = 0
Dim i As Integer
Dim pay_id As Integer
Dim status As Boolean
Dim chno As Integer
Dim bname As String
Dim c_no As Integer = 0
Dim b_name As String = ""
Private Sub setCon(ByRef strsql As String)
Try
con = New SqlConnection("Data Source=BSC-13\SQLEXPRESS;
Initial Catalog=bookingdatabase;Integrated Security=True")
Module1.connection()
da = New SqlDataAdapter(strsql, Module1.con)
ds = New DataSet
da.Fill(ds, "payment")
dv = New DataView(ds.Tables("payment"))
Catch ex As Exception
MsgBox(ex.ToString)
End Try
End Sub
82
Builder and Developer 2015
While dr1.Read
cmbcustid.Items.Add(dr1("Cust_ID").ToString())
End While
dr1.Close()
Module1.con.Close()
Catch ex As Exception
MsgBox(ex.ToString)
End Try
Try
cmd = New SqlCommand("select Pay_ID from tblpay_details", Module1.con)
Module1.con.Open()
dr = cmd.ExecuteReader
While dr.Read
cmbsearch.Items.Add(dr("Pay_ID").ToString())
End While
dr.Close()
Module1.con.Close()
Catch ex As Exception
MsgBox(ex.ToString)
End Try
End Sub
Private Sub btnadd_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnadd.Click
If btnadd.Text = "Add" Then
Call setFields(False)
btnadd.Enabled = True
btnExit.Enabled = True
btnadd.Text = "Save"
btnExit.Text = "Cancel"
pay_id = key_autogenerate()
Call clearFields()
setTextfields(True)
cmbpay_id.Text = pay_id
ElseIf btnadd.Text = "Save" Then
Try
If cmbpay_id.Text = "" And cmbcustid.Text = "" And txtcust_name.Text = ""
And dtpboo_date.Text = "" And dtppay_date.Text = "" And txttotal_amnt.Text = "" And
txtamnt_paid.Text = "" And txtamnt_bal.Text = "" Then
MsgBox("Please fill all the fields")
ElseIf cmbpay_id.Text = "" Then
MsgBox("Please enter payment id properly")
cmbpay_id.Focus()
ElseIf cmbcustid.Text = "" Then
MsgBox("Please enter your id")
cmbcustid.Focus()
ElseIf txtcust_name.Text = "" Then
MsgBox("Please enter your name.")
txtcust_name.Focus()
ElseIf dtpboo_date.Text = "" Then
85
Builder and Developer 2015
End Sub
Private Sub btnExit_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnExit.Click
If btnExit.Text = "Exit" Then
End
ElseIf btnExit.Text = "Cancel" Then
btnadd.Text = "Add"
btnExit.Text = "Exit"
clearFields()
setFields(True)
setTextfields(False)
End If
End Sub
Private Sub btnclear_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnclear.Click
clearFields()
End Sub
Private Sub btnsearch_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnsearch.Click
Try
con.Open()
cmd = New SqlCommand
cmd.Connection = con
cmd.CommandType = CommandType.Text
If cmbsearch.Text <> "" Then
cmd.CommandText = "select * from tblpay_details where Pay_ID="
& cmbsearch.Text & ""
dr = cmd.ExecuteReader()
dr.Read()
cmbpay_id.Text = dr("Pay_ID")
cmbcustid.Text = dr("Cust_ID")
txtcust_name.Text = dr("Cust_Name")
dtpboo_date.Text = dr("Booking_Date")
dtppay_date.Text = dr("Payment_Date")
cmbpaymode.Text = dr("Pay_Mode")
txttotal_amnt.Text = dr("Total_Amnt")
txtamnt_paid.Text = dr("Amnt_Paid")
txtamnt_bal.Text = dr("Amnt_Bal")
txtbank_name.Text = dr("Bank_Name")
txtcheq_no.Text = dr("Cheq_No")
cmbtrans.Text = dr("Paytrans")
dr.Close()
con.Close()
Else
MsgBox("Pls Enter the Id to be viewed")
End If
Catch ex As Exception
End Try
con.Close()
88
Builder and Developer 2015
End Sub
Private Sub btnFirst_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnFirst.Click
Me.BindingContext(dv).Position = 0
rowcount = 0
End Sub
Private Sub btnPrevious_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnPrevious.Click
rowcount = rowcount - 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position - 1
If rowcount < 0 Then
MsgBox("First Record")
rowcount = 0
End If
End Sub
Private Sub btnNext_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnNext.Click
rowcount = rowcount + 1
Me.BindingContext(dv).Position = Me.BindingContext(dv).Position + 1
If rowcount = ds.Tables(0).Rows.Count Then
MsgBox("Last Record")
rowcount = rowcount - 1
End If
End Sub
Private Sub btnLast_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles btnLast.Click
BindFields()
Me.BindingContext(dv).Position = Me.BindingContext(dv).Count - 1
rowcount = ds.Tables(0).Rows.Count - 1
End Sub
Private Sub cmbcustid_SelectedIndexChanged(ByVal sender As System.Object, ByVal
e As System.EventArgs) Handles cmbcustid.SelectedIndexChanged
Try
Dim cmd1 As SqlCommand
Module1.con.Close()
Module1.con.Open()
cmd1 = New SqlCommand("select * from tblreg_details where Cust_ID="
& cmbcustid.Text & "", Module1.con)
dr = cmd1.ExecuteReader
dr.Read()
txtcust_name.Text = dr("Cust_Name").ToString()
txtcust_name.Enabled = False
dtpboo_date.Text = dr("Booking_Date").ToString()
dtpboo_date.Enabled = False
txttotal_amnt.Text = dr("Total_Amnt").ToString()
txttotal_amnt.Enabled = False
dr.Close()
Module1.con.Close()
Catch ex As Exception
89
Builder and Developer 2015
MsgBox(ex.ToString)
End Try
End Sub
Private Sub cmbpaymode_SelectedIndexChanged(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles cmbpaymode.SelectedIndexChanged
If cmbpaymode.Text = "Cheque" Then
Cheque.Visible = True
status = True
Else
Cheque.Visible = False
chno = 0
bname = "NA"
status = False
End If
End Sub
Private Sub txtamnt_bal_GotFocus(ByVal sender As Object, ByVal e
As System.EventArgs) Handles txtamnt_bal.GotFocus
txtamnt_bal.Text = CInt(txttotal_amnt.Text) - CInt(txtamnt_paid.Text)
txttotal_amnt.Enabled = False
End Sub
End Class
90
Builder and Developer 2015
SCREEN
LAYOUTS
AND
91
Builder and Developer 2015
REPORT
LAYOUTS
92
Builder and Developer 2015
LOGIN:
93
Builder and Developer 2015
MAINFORM FORM:
94
Builder and Developer 2015
95
Builder and Developer 2015
96
Builder and Developer 2015
97
Builder and Developer 2015
98
Builder and Developer 2015
99
Builder and Developer 2015
100
Builder and Developer 2015
101
Builder and Developer 2015
102
Builder and Developer 2015
103
Builder and Developer 2015
104
Builder and Developer 2015
TESTING
Testing Objectives
A good test case is one that has a high probability of finding yet not
discovered errors.
Unit Testing
Integration Testing
105
Builder and Developer 2015
Code Testing
The code testing examines the logic of the program. To
follow this testing we have developed test cases that result in
every instruction in the module; every path is specific
combination of conditions that is handled by the program
Validation Testing
Validation testing to validate system functionalities, that they
are traceable to customer requirements.
System Testing
System testing to test efficiency with all minimum hardware
and software requirements of system after installation
106
Builder and Developer 2015
Future Scope
In future, a system may be developed which can be used online by the users
who want to sale or purchase properties. In such a system the users may deal
directly with each other, they do not need a property dealer as an
intermediate. Also they are not supposed to go to the property dealer for their
deals; they can directly use the software online. Moreover the users do not
need to pay extra amounts as in case of a property dealer who helped in the
deals, whatever amount the seller needs, is paid by the purchaser. This saves
money as well as time too. So, in future a lot of manipulations can be done
keeping in view the requirements of the users.
107
Builder and Developer 2015
Conclusion
108
Builder and Developer 2015
With the use of this software, the property dealer does not need to store the
records of dealings into registers or papers. So, it becomes easier for him to
keep the records for future references. Also it becomes much easier to keep a
record of properties which are being sold or which are not sold yet. Thus this
system saves time and is easier to use. Moreover, it is efficient software for
property dealers.
REFERENCES / BIBLIOGRAPHY
Bibliography:
• www.w3school.com
• www.wikipedia.org
• www.msdn.microsoft.com/en-us/vstudio/default.aspx
References:
109
Builder and Developer 2015
110