Beruflich Dokumente
Kultur Dokumente
0
Sr. Contents
No.
1 Introduction
1.1 Introduction to Café Coffee Day 1
1.2 Need
Preface
2
Existing System 3
Drawback of the Existing System 4
2 Introduction to Visual Basic 5
3 Introduction to Access Database 7
4 Need of Computerization 9
5 User requirement 10
6 Process system 12
7 System requirement 13
8 Requirement analysis & specification 16
9 Table Structure 18
10 Data Flow Diagram 19
11 E-R Diagram 20
12 Source Code 22
13 Screen layout 36
14 User interface 45
15 Testing processer 48
16 Report 50
17 System & limitation 51
18 Enhancement 52
19 Scope of project 53
20 Conclusion 54
21 Bibliography 55
INTRODUCTION TO
CAFÉ COFFEE DAY SYSTEM
1
The Café Coffee Day System version 1.0 is a very interactive and
fast software which really lets user to save his time and keeps him off
from all the tedious jobs for finding records and doing all the stuff with
Coffee Shop Bill.
The most striking feature of the software is that it has been
provided with a very simple and fast procedure to buy coffee and
checking up for the coffee available it can buy a Coffee. In this procedure
the customer will not have to do anything and not to get bothered about
filling up all the above information, only the user will do all the work.
In the same way the software has been provided with the
management of all the Coffee and all the account information of Coffee
shop. It can find out the information of the Coffee just by clicking
product list button.
2
PREFACE
3
EXISTINGSYSTEM
If any customer come to the shop, he/she is displayed all the clothes
available in the boutique.
4
DRAWBACKS OF EXISTING SYSTEM
3. Lack of manpower.
Thus existing system has various problem , which leads towards need
of computerization.
5
INTRODUCTION TO VISUAL BASIC
6
to a standard (and more efficient) OLE DB provider when the porting of
the code is complete and You’re ready to convert the database data to
SQL Server or another major database engine for which a standard OLE
DB provider exists.
Before you get too enthusiastic, keep in mind that Visual Basic
doesn’t allow you to write full-fledged OLE DB providers such as those
that Microsoft has created for the Microsoft Jet Database Engine, SQL
Server, or Oracle. An OLE DB simple provider doesn’t support
transactions, Command objects, and batch updates, just to mention a few
of its limitations. Another problem with these providers is that they don’t
expose information about the structure of the data: They can return the
name of a column, but they don’t expose a column’s data type or
maximum length. OLE DB Simple Providers are especially good at
exposing table data that can be stored in an array in memory. These
restrictions don’t keep you from doing interesting things with OLE DB
simple providers, however. For example, you can create a provider that
accesses Excel or Microsoft Outlook Programs, or from any other
program that you can control through Automation.
7
INTRODUCTION TO ACCESS DATABASES
8
Data Control Language (DCL): this is used for controlling data and
their access to the database.
A database is a collection of information that’s related to a
particular subject or purpose, such as tracking customer orders or
maintaining a music collection. If your database isn’t stored on a
computer, or only parts of it are, you may be tracking information from a
variety of sources that you’re having to coordinate and organize yourself.
For example, suppose the phone numbers of your suppliers are
stored in various locations: in a card file containing supplier phone
numbers, in product information files in a file cabinet, and in a
spreadsheet containing order information. If a supplier’s phone number
changes, you might have to update that information in all three places. In
a database, however, you only have to update that information in one
place- the supplier’s phone number is automatically updated wherever
you use it in the database.
9
NEED OF COMPUTERIZATION
The next and also an important feature is that it reduces the man
power and makes the job easy to use for the user.
The storage capacity of the records increases and can keep the
records for the long time of period with misplacing the records.
10
USER REQUIREMENT
1) Technical Requirement :
11
to the system a change in general and increased the likelihood of
successful project.
The simple GUI with a user – friendly data screens make the user
completely free to work with the system.
12
ROPOSED SYSTEMP
Prompt services
Online data entry facility
Paperless office
Reduction of manpower
13
SYSTEM REQUIREMENT
Unit Testing
Module testing
14
A module is a collection of dependant components such as on
object class, an abstract data type or some looser collection of
procedures and function .
Sub-module testing
Acceptance testing
This is the final stage in the testing process before the system is
accepted for operational use. The system is tested with data supplied
by the system procurer rather than simulated test data. Acceptance
testing may reveal errors and omission in the system requirement
definition because the real data exercises the system in different
ways from the test data. Acceptance testing may also reveal the
requirement problems where the system’s facilities do not really meet
the user’s needs or the system performance is acceptable.
15
REQUIREMENT ANALYSIS & SPECIFICATION
16
4. The introduction of SRS states the goals & objectives of software
Components Of SRS –
a. Functionality requirements
b. Reference requirements
c. Design constraints
d. External interface
17
TABLES
LOGIN TABLE
PRODUCT MASTER
BILL MASTER
18
DATA FLOW DIAGRAM
19
E R - DIAGRAM
Prod PRODNAM
E
no
BILL DATE
STOCK
QTY BILLN
O
PRODUCT PRODNO
SALEQTY
RATE BILL
RATE
CUST BUYS
PRODUCT
20
SOURCE
CODE
22
MDIForm
End Sub
23
Case "Product_Entry"
mnuprodEntry_Click
Case "Bill_Entry"
mnubillentry_Click
Case "Product_List"
mnuprodlist_Click
Case "Logout"
mnulogout_Click
Case "About"
mnuabout_Click
End Select
End Sub
24
THE PRODUCT ENTRY CODING
Dim con As New ADODB.Connection
Dim rs As New ADODB.Recordset
Dim rs2 As New ADODB.Recordset
Dim cmd As New ADODB.Command
Dim addflag As Boolean
Dim cancelflag As Boolean
Private Sub cmdadd_Click()
On Error GoTo chkerr
Dim s As String
cancelflag = True
txtProdno.Text = ""
txtprodname.Text = ""
txtstockqty.Text = ""
txtrate.Text = ""
txtcatg.Text = ""
ButtonDisabled
addflag = True
txtProdno.Locked = True
s = "select max(PRODNO) from PRODUCTMASTER"
rs2.Open s, con, adOpenDynamic, adLockOptimistic, adCmdText
rs2.MoveFirst
If Not rs2.EOF Then
txtProdno.Text = rs2.Fields(0) + 1
GoTo bottom
End If
chkerr:
txtProdno.Text = 1
bottom:
rs2.Close
txtprodname.SetFocus
End Sub
Private Sub CmdCancel_Click()
On Error Resume Next
ButtonEnabled
addflag = False
rs.MoveFirst
ShowRecord
End Sub
Private Sub cmdExit_Click()
cancelflag = True
25
con.Close
Unload Me
End Sub
Private Sub cmddel_Click()
On Error GoTo chkerr
Dim str As String
ans = MsgBox(" Delete ? ", vbYesNo + vbDefaultButton2 +
vbCritical, " Product Deletion")
If ans = vbYes Then
str = " delete from PRODUCTMASTER where PRODNO = " &
Val(txtProdno.Text)
cmd.ActiveConnection = con
cmd.CommandType = adCmdText
cmd.CommandText = str
cmd.Execute
rs.Requery
rs.MoveNext
ShowRecord
End If
GoTo enddata
chkerr:
MsgBox " Can not delete "
enddata:
End Sub
Private Sub CmdFirst_Click()
On Error Resume Next
rs.MoveFirst
ShowRecord
End Sub
Private Sub CmdLast_Click()
On Error Resume Next
rs.MoveLast
ShowRecord
End Sub
Private Sub CmdNext_Click()
On Error Resume Next
rs.MoveNext
If rs.EOF Then rs.MoveLast
ShowRecord
End Sub
Private Sub cmdPrev_Click()
On Error Resume Next
rs.MovePrevious
26
If rs.BOF Then rs.MoveFirst
ShowRecord
End Sub
Private Sub cmdsave_Click()
On Error Resume Next
Dim str As String
If addflag = True Then
str = "insert into PRODUCTMASTER values (" & Val(txtProdno.Text)
& ",'" & UCase(txtprodname.Text) & "'," & txtstockqty.Text & " , " &
Val(txtrate.Text) & ",'" & UCase(txtcatg.Text) & "') "
Else
str = "update PRODUCTMASTER set Prodname ='" &
UCase(txtprodname.Text) & _
"' , STOCKQTY = " & Val(txtstockqty.Text) & _
" , RATE = " & Val(txtrate.Text) & _
" , Category = '" & UCase(txtcatg.Text) & _
"' where PRODNO=" & Val(txtProdno.Text)
End If
cmd.ActiveConnection = con
cmd.CommandType = adCmdText
cmd.CommandText = str
cmd.Execute
rs.Requery
addflag = False
ButtonEnabled
txtProdno.Locked = True
End Sub
Private Sub cmdupdate_Click()
ButtonDisabled
txtProdno.Locked = True
End Sub
Private Sub Form_Load()
On Error Resume Next
cmdsave.Enabled = False
cmdCancel.Enabled = False
addflag = False
con.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=" & App.Path & "\Cafe.mdb;Persist Security Info=False"
con.Open
rs.Open "PRODUCTMASTER", con, adOpenDynamic,
adLockOptimistic, adCmdTable
rs.MoveFirst
27
ShowRecord
End Sub
Public Sub ShowRecord()
On Error Resume Next
txtProdno.Text = rs.Fields("PRODNO")
txtprodname.Text = rs.Fields("PRODNAME")
txtstockqty.Text = rs.Fields("STOCKQTY")
txtrate.Text = rs.Fields("RATE")
txtcatg.Text = rs.Fields("Category")
End Sub
Public Sub ButtonDisabled()
CmdFirst.Enabled = False
CmdNext.Enabled = False
cmdPrev.Enabled = False
CmdLast.Enabled = False
cmdadd.Enabled = False
cmdupdate.Enabled = False
cmddel.Enabled = False
cmdsave.Enabled = True
cmdCancel.Enabled = True
End Sub
Public Sub ButtonEnabled()
CmdFirst.Enabled = True
CmdNext.Enabled = True
cmdPrev.Enabled = True
CmdLast.Enabled = True
cmdadd.Enabled = True
cmdupdate.Enabled = True
cmddel.Enabled = True
cmdsave.Enabled = False
cmdCancel.Enabled = False
End Sub
28
txtstockqty.Text = Val(txtstockqty.Text)
If Val(txtstockqty.Text) < 0 Then
MsgBox "Please enter stock "
Cancel = True
End If
End Sub
Private Sub txtstockqty_KeyPress(KeyAscii As Integer)
If Not ((KeyAscii >= 48 And KeyAscii <= 57) Or KeyAscii = 8) Then
KeyAscii = 0
End If
End Sub
29
THE PRODUCTLIST FORM CODING TO SHOW
PRODUCTLIST ON GRID
Grid.ColWidth(0) = 1600
Grid.ColWidth(1) = 2500
Grid.ColWidth(2) = 2500
Grid.ColWidth(3) = 1500
Grid.ColWidth(4) = 2000
n=1
While rs.EOF = False
Grid.Rows = Grid.Rows + 1
Grid.TextMatrix(n, 0) = rs!PRODNO
Grid.TextMatrix(n, 1) = rs!PRODNAME
Grid.TextMatrix(n, 2) = rs!STOCKQTY
Grid.TextMatrix(n, 3) = rs!rate
Grid.TextMatrix(n, 4) = rs!Category
rs.MoveNext
n=n+1
Wend
rs.Close
con.Close
End Sub
30
Private Sub prodlistClose_Click()
Unload Me
End Sub
31
New ADODB.Connection
Dim rs As New ADODB.Recordset
Dim rs2 As New ADODB.Recordset
Dim rs3 As New ADODB.Recordset
Dim cmd As New ADODB.Command
Dim pno As Integer
Dim rowno As Integer
Dim closeflag As Boolean
32
rs2.MoveFirst
If Not rs2.EOF Then
txtbillno.Text = rs2.Fields(0) + 1
End If
GoTo enddata
chkerr:
txtbillno.Text = 1
enddata:
rs2.Close
End Sub
Private Sub cmdsave_Click()
On Error Resume Next
Dim str As String
Dim ctr As Integer
Dim billno As Integer
Dim pno As Integer
Dim qty As Integer
Dim rate As Integer
Dim dt As Date
ctr = 1
billno = Val(txtbillno.Text)
dt = Format(txtbilldate.Text, "dd-mmm-yyyy hh:mm:ss")
rs.Open "BILLMASTER", con, adOpenDynamic, adLockOptimistic,
adCmdTable
str = "insert into BILLMASTER values (" & Val(txtbillno.Text) & ",'" &
dt & "')"
cmd.ActiveConnection = con
cmd.CommandType = adCmdText
cmd.CommandText = str
cmd.Execute
rs.Requery
rs.Close
rs2.Open "BILLDETAIL", con, adOpenDynamic, adLockOptimistic,
adCmdTable
rs3.Open "PRODUCTMASTER", con, adOpenDynamic,
adLockOptimistic, adCmdTable
Do While ctr < rowno
pno = MSHFlexGrid1.TextMatrix(ctr, 1)
qty = MSHFlexGrid1.TextMatrix(ctr, 3)
rate = MSHFlexGrid1.TextMatrix(ctr, 4)
str = " insert into BILLDETAIL values ( " & billno & " , " & pno & " , "
& qty & " ," & rate & " ) "
cmd.ActiveConnection = con
33
cmd.CommandType = adCmdText
cmd.CommandText = str
cmd.Execute
rs2.Requery
str = "update PRODUCTMASTER set STOCKQTY = STOCKQTY - "
& qty & " where PRODNO = " & pno
cmd.ActiveConnection = con
cmd.CommandType = adCmdText
cmd.CommandText = str
cmd.Execute
rs3.Requery
ctr = ctr + 1
Loop
rs2.Close
rs3.Close
MsgBox " Bill Print...", vbInformation, "Print Bill"
On Error GoTo chkerr
DataEnvironment1.Command4 billno
DataReportBillPrint.Show vbModal
GoTo last
chkerr:
DataEnvironment1.Connection1.Close
DataEnvironment1.Connection1.Open
DataEnvironment1.Command4 billno
DataReportBillPrint.Show vbModal
last:
cmdsave.Enabled = False
cmdnewbill.SetFocus
End Sub
Private Sub cmdselect_Click()
Dim s As String
Dim pno, qty, rate As Integer
Dim ctr, amt As Integer
ctr = 1
amt = 0
If Len(txtqty.Text) = 0 Then
MsgBox " Enter Qty ", vbInformation, "COFFEE Qty "
txtqty.SetFocus
Exit Sub
End If
s = " select * from PRODUCTMASTER where PRODNAME = '" &
cmbprodname.Text & "'"
rs2.Open s, con, adOpenDynamic, adLockOptimistic, adCmdText
34
rs2.MoveFirst
pno = rs2.Fields("PRODNO")
rs2.Close
MSHFlexGrid1.TextMatrix(rowno, 0) = rowno
MSHFlexGrid1.TextMatrix(rowno, 1) = pno
MSHFlexGrid1.TextMatrix(rowno, 2) = cmbprodname.Text
MSHFlexGrid1.TextMatrix(rowno, 3) = txtqty.Text
MSHFlexGrid1.TextMatrix(rowno, 4) = txtrate.Text
MSHFlexGrid1.TextMatrix(rowno, 5) = Val(txtqty.Text) *
Val(txtrate.Text)
Do While ctr <= rowno
qty = MSHFlexGrid1.TextMatrix(ctr, 3)
rate = MSHFlexGrid1.TextMatrix(ctr, 4)
amt = amt + (qty * rate)
ctr = ctr + 1
Loop
txtbillamount.Text = amt
rowno = rowno + 1
MSHFlexGrid1.Rows = MSHFlexGrid1.Rows + 1
cmdsave.Enabled = True
End Sub
Private Sub Form_Load()
On Error Resume Next
cmdsave.Enabled = False
cmdselect.Enabled = False
con.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data
Source=" & App.Path & "\Cafe.mdb;Persist Security Info=False"
con.Open
'Call productlist
closeflag = False
'Call gridformat
Call cmdnewbill_Click
End Sub
Private Sub productlist()
On Error Resume Next
Dim s As String
s = "select * from productmaster where stockqty > 0 "
rs2.Open s, con, adOpenDynamic, adLockOptimistic, adCmdText
cmbprodname.Clear
rs2.MoveFirst
Do While Not rs2.EOF
cmbprodname.AddItem rs2.Fields("prodname")
rs2.MoveNext
35
Loop
rs2.Close
End Sub
Private Sub gridformat()
MSHFlexGrid1.Cols = 6
MSHFlexGrid1.ColWidth(0) = 800
MSHFlexGrid1.ColWidth(1) = 1500
MSHFlexGrid1.ColWidth(2) = 2400
MSHFlexGrid1.ColWidth(3) = 1000
MSHFlexGrid1.ColWidth(4) = 1000
MSHFlexGrid1.ColWidth(5) = 1500
MSHFlexGrid1.TextMatrix(0, 0) = "Sr No"
MSHFlexGrid1.TextMatrix(0, 1) = "Product No"
MSHFlexGrid1.TextMatrix(0, 2) = "Product Name "
MSHFlexGrid1.TextMatrix(0, 3) = "Qty"
MSHFlexGrid1.TextMatrix(0, 4) = " Rate"
MSHFlexGrid1.TextMatrix(0, 5) = " Amount"
End Sub
Private Sub txtqty_KeyPress(KeyAscii As Integer)
If Not ((KeyAscii >= 48 And KeyAscii <= 57) Or KeyAscii = 8) Then
KeyAscii = 0
End If
End Sub
Private Sub txtqty_Validate(Cancel As Boolean)
Dim a As Integer
Dim stk As Integer
stk = Val(txtstockqty.Text)
a = Val(txtqty.Text)
If closeflag = False Then
If a <= 0 Then
MsgBox " sale qty can not be <=0 ", vbCritical
Cancel = True
End If
If a > stk Then
MsgBox " Not enough stock , order <= " & stk, vbCritical
Cancel = True
End If
End If
End Sub
36
SCREENS
LAYOUT
37
LOGIN WINDOW:
LOGIN WINDOW:
38
MDI FORM:
This form gives the detail of Product entry form, Bill entry
form, Bill Report, Product list form & about the software developer & its
version detail.
MDI FORM:
39
PRODUCT MASTER FORM:
This form gives information about product stock, its price, Product
category, Product number. It also provides Updating in product Stock,
product rates & its category, user can add, save, or delete the product
from available.
40
PRODUCT LIST FORM:
41
SOFTWARE INFORMATION FORM:
42
BILL ENTRY FORM:
This form provides the platform to enter the entry of selling all the
product’s to customer & provides bill generating platform. Here fill’s all
the detail that user have been purchased product.
43
BILLING FORM:
44
BILL REPORT FORM:
This is the bill report, which will be providing to the customer. This
45
USER INTERFACE
Main Menu:-
Enter
Forms
Reports
Help
1) Enter:-
Login
Exit
On clicking login we make the login entry and proceed with the
project further , clicking exit we get back to the original state . If the
option form menu is selected then following sub menu appears on
the screen.
Form:-
46
Data entry screen for Computer Entry
Data entry screen for Service Entry
When we start with form menu we get the details of entry screen for
Computer entry, Service entry, Bill entry.
If the option Report menu is selected then following sub menu appears on
the screen.
2) Report:-
47
3) Help:-
About Software
POST IMPLEMENTATION
Implementation:
48
TESTING PROCEDURE
Recovery Testing
Stress Testing
Performance Testing
Performance testing for the application is performed for finding the actual
run-time performance. Time taken for search and locate the required data
is tested. The data conversion accuracy and speed for the converter tool is
also tested. Connectivity and data transfer performance for live update
facility of the application is tested by using test data sets provided by the
system testing specialists of the company.
49
cycle. since, here; it involves the customer and intends to check that the
tests dispose no errors at all. All the possible testing conditions and
data that the software organization has never seen will fall within the
specified operational conditions and behavior of the software. The
proposed system is very efficient and perfect than the existing one. The
modules available are very user friendly and also completely devoid
of all the possible input errors. The user proves it by using sample
data.
50
REPORTS
When we start with form menu we get the details of entry screen for
Computer entry, Service entry, Bill entry.
If the option Report menu is selected then following sub menu appears on
the screen.
Report:-
51
SYSTEM & LIMITATIONS
52
ENHANCEMENT
The structure tools focuses on the tools listed earlier like Data Flow
Diagram (DFD), Data Dictionary (DD). Structured English, Decision
trees and Decision tables.
53
SCOPE OF THE PROJECT
have provided three separate sections i.e. Product entry, Product detail
list, & bill receipt so that they can maintain records easily. Though we are
providing them all their product entry & account transactions but, in
product‘s and also able to modify, delete & save the changes in their
product’s.
54
CONCLUSION
has come true. The successful working of the computerized system is due
The reason for our success is teamwork. Every one of us gives his
and makes them easy to handle the transactions and keep the records of
transactions.
55
BIBLIOGRAPHY
1. MS-ACCESS
Author - IRON BAY ROSS
56