Rabu, 13 Desember 2017

Tugas 3.1 BP1

Private Sub Command1_Click()
Text1 = ""
Text2 = ""
Text3 = ""
Text4 = ""
Text5 = ""
Text6 = ""
Combo1 = ""
End Sub

Private Sub Form_load()
Combo1.AddItem "I"
Combo1.AddItem "II"
Combo1.AddItem "III"
Combo1.AddItem "IV"
End Sub


Private Sub Command2_Click()
Text1 = ""
Text2 = ""
Text3 = ""
Text4 = ""
Text5 = ""
Text6 = ""
Combo1 = ""
End Sub

Private Sub Command3_Click()
Unload Me
End Sub

Private Sub combo1_Click()
Dim gapok, pajak, tunjangan, total As Variant
Select Case Combo1.Text
Case "I"
gapok = 6000000
tunjangan = 250000
Case "II"
gapok = 7000000
tunjangan = 250000
Case "III"
gapok = 5500000
tunjangan = 250000
Case "IV"
gapok = 3000000
tunjangan = 300000
Case Else
gapok = 0
tunjangan = 0
End Select
total = gapok + tunjangan
pajak = total * 0.1
Text3= gapok
Text4 = tunjangan
Text5 = pajak
Text6 = total - pajak
End Sub


Tidak ada komentar:

Posting Komentar