MCA Lab Report 1
MCA Lab Report 1
LAB 1
Start
Calculate charges
RC = Night * NC
AC = RS + Tel + Misc
Subtotal = RC + AC
Tax = 0.08 * Subtotal
TC = Subtotal + Tax
Label17.Text = RC.ToString("C")
Label18.Text = AC.ToString("C")
Label19.Text = Subtot.ToString("C")
Label20.Text = Tax.ToString("C")
Label21.Text =TC .ToString("C")
Display result
Clear
Stop
2. PROGRAMMING
FORM 1
Public Class Form1
Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Label4.Text = Now.ToString("D") 'Displays Day & Date
Label5.Text = Now.ToString("hh:mm:ss tt") 'Displays Time
End Sub
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Dim a, b, c, d, f, v, w, x, y, z As Double
v = (a * b) 'Calculation formula
w = (c + d + f)
x = (v + w)
y = (x * 0.08)
z = (x + y)
End Sub
CLEAR
Label16.Text = ""
Label17.Text = ""
Label18.Text = ""
Label19.Text = ""
Label20.Text = ""
End Sub
EXIT
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
End 'Exits the program
End Sub
End Class
5. DISCUSSION
Visual Basic is widely used to write working programs. In this experiment, Room
Charger Calculator is executed by using create Graphical User Interface and use Visual Basic
development tools.