Entri Populer

Program VB


Bilangan Ganjil vs Genap

Listing Program

Private Sub Command1_Click()
Dim a As Single
Dim b As Integer
Dim c As Single
a = Val(Text1.Text) / 2
b = Val(Text1.Text) \ 2
c = a – b
If c = 0# Then
Label2.Caption = “Bilangan Genap”
Else
Label2.Caption = “Bilangan Ganjil”
End If
End Sub

Private Sub Command2_Click()
Text1.Text = “”
Label2.Caption = “”
End Sub

Private Sub Command3_Click()
Unload Me
End Sub


Output ( Click to Try Program)





























0 komentar:

About Me

Foto Saya
Satrio Dwi Laksono
System Information student of Gunadarma University
Lihat profil lengkapku