membuat program gaji sederhana di vb

listing programnya

Private Sub Command1_Click()
If Text2.Text = “A” Then
Text4.Text = 1000
Text5.Text = 500
If Text3.Text > 40 Then
Text6.Text = (Text3.Text – 40) * 500
Text7.Text = Val(Text4.Text) + Val(Text5.Text) + Val(Text6.Text)
Else
Text6.Text = “TIDAK ADA LEMBURAN”
Text7.Text = Val(Text4.Text) + Val(Text5.Text)
End If
Else
If Text2.Text = “B” Then
Text4.Text = 1500
Text5.Text = 800
If Text3.Text > 40 Then
Text6.Text = (Text3.Text – 40) * 500
Text7.Text = Val(Text4.Text) + Val(Text5.Text) + Val(Text6.Text)
Else
Text6.Text = “TIDAK ADA LEMBURAN”
Text7.Text = Val(Text4.Text) + Val(Text5.Text)
End If
Else
If Text2.Text = “C” Then
Text4.Text = 2000
Text5.Text = 1000
If Text3.Text > 40 Then
Text6.Text = (Text3.Text – 40) * 500
Text7.Text = Val(Text4.Text) + Val(Text5.Text) + Val(Text6.Text)
Else
Text6.Text = “TIDAK ADA LEMBURAN”
Text7.Text = Val(Text4.Text) + Val(Text5.Text)
End If
End If
End If
End If

Text1.SetFocus
End Sub

Private Sub Command2_Click()
If MsgBox(“Anda Yakin Keluar”, vbOKCancel + vbDefaultButton2, “Tutup Aplikasi”) = vbOK Then
End
End If
End Sub

About these ads

2 Tanggapan

  1. klw bsa yg lengkap donk mas
    tp thanx lah

  2. THANKS atas contohnya
    good job

Berikan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Logout / Ubah )

Twitter picture

You are commenting using your Twitter account. Logout / Ubah )

Facebook photo

You are commenting using your Facebook account. Logout / Ubah )

Google+ photo

You are commenting using your Google+ account. Logout / Ubah )

Connecting to %s

Ikuti

Get every new post delivered to your Inbox.

%d blogger menyukai ini: