Febriawan Indra Wijanarko (1006724362)
Aplikasi ini tentang bill pembelian buah secara grosir yang masih terbatas jumlah barangnya.
di sini kita hanya memilih buah dan jumlah yg ingin kita beli.
Coding Aplikasi VB
Public Class Form1
Private Sub CB1_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CB1.SelectedIndexChanged
If CB1.Text = "Jeruk" Then
TB1.Text = 5000
Else
If CB1.Text = "Jambu" Then
TB1.Text = 3500
Else
CB1.Text = "Apel"
TB1.Text = 6000
End If
End If
End Sub
Private Sub CB2_SelectedIndexChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CB2.SelectedIndexChanged
TB3.Text = CB2.Text * TB1.Text
If CB2.Text = 1 Then
RB1.Checked = True
RB2.Checked = False
RB3.Checked = False
Else
If CB2.Text = 2 Then
RB1.Checked = True
RB2.Checked = False
RB3.Checked = False
Else
If CB2.Text = 3 Then
RB1.Checked = True
RB2.Checked = False
RB3.Checked = False
Else
If CB2.Text = 4 Then
RB1.Checked = True
RB2.Checked = False
RB3.Checked = False
Else
If CB2.Text = 5 Then
RB1.Checked = True
RB2.Checked = False
RB3.Checked = False
Else
If CB2.Text = 6 Then
RB2.Checked = True
RB1.Checked = False
RB3.Checked = False
Else
If CB2.Text = 7 Then
RB2.Checked = True
RB1.Checked = False
RB3.Checked = False
Else
If CB2.Text = 8 Then
RB2.Checked = True
RB1.Checked = False
RB3.Checked = False
Else
If CB2.Text = 9 Then
RB2.Checked = True
RB1.Checked = False
RB3.Checked = False
Else
If CB2.Text = 10 Then
RB2.Checked = True
RB1.Checked = False
RB3.Checked = False
Else
If CB2.Text = 11 Then
RB3.Checked = True
RB2.Checked = False
RB1.Checked = False
Else
If CB2.Text = 12 Then
RB3.Checked = True
RB2.Checked = False
RB1.Checked = False
Else
If CB2.Text = 13 Then
RB3.Checked = True
RB2.Checked = False
RB1.Checked = False
Else
If CB2.Text = 14 Then
RB3.Checked = True
RB2.Checked = False
RB1.Checked = False
Else
CB2.Text = 15
RB3.Checked = True
RB2.Checked = False
RB1.Checked = False
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End If
End Sub
Private Sub RB1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RB1.CheckedChanged
TB4.Text = TB3.Text * 0 / 100
End Sub
Private Sub RB2_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RB2.CheckedChanged
TB4.Text = TB3.Text * 5 / 100
End Sub
Private Sub RB3_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles RB3.CheckedChanged
TB4.Text = TB3.Text * 7 / 100
End Sub
Private Sub TB4_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TB4.TextChanged
TB5.Text = TB3.Text - TB4.Text
End Sub
Private Sub B2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles B2.Click
MessageBox.Show("Selesai", "Keterangan", MessageBoxButtons.OK,MessageBoxIcon.Asterisk)
End Sub
End Class
Screenshot Formnya….
Yang ini juga screenshotnya….