Module Module1
'variabel public
Public nama As String, hasil, h, b As Integer
Sub tampilnama()
nama = "Teknik Informatika"
End Sub
Sub hitung()
hasil = Val(h) * Val(b)
End Sub
End Module
Public Class Form1
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
Call tampilnama()
h = TextBox2.Text
b = TextBox3.Text
Call hitung()
TextBox1.Text = hasil
End Sub
Private Sub TextBox2_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox2.TextChanged
End Sub
End Class
0 komentar
Posting Komentar