You are on page 1of 4

ASSIGMENT 3

Unique no:795129

21 April
56463723

Case:

Write a program to calculate the water bill when a user clicks on a button.

1.1

Task Object Event


Get the following water consumption information from
user: OldreadTxtBox None
Enter amount NewreadTxtBox None
Enter amount
Calculate water consumption CalcConsumption
Calculate water bill BillButtton click
Display the following information:
Water consumption CalcConsumption,ConsumptionLab None
Total water bill el None
YourbillLabel
End the program Exitbutton click
TOE Chart

1.2 Flowchart Design

1
56463723

Start Program CalculateWaterBill


ca
calculate waterbil

calculare water bill

C ca ca
ca
C= amount + amount

Input:
oldread,new
read
::

Is reading
numeric and
read1>=read2 No

Yes

Convert readstring to readnumber

Is
No consu
mption
<=4

Yes
es

Yes
Is consumption 4>=9

No
Consumption*5
Consumption*3

Is
Yes consu
mptio
n >9

No

Output: Consumption *2 Output:


BILL Error message

exit page
exit page
EndProgram

56463723

1.3

Sketch: vertical arrangement of the Water-Bill Interface

WATER BILL

Enter

Oldread:

Newread:

Consumption:

BILL Exit

You might also like