Selasa, 21 November 2017

Tugas 2.5

Tugas 2.5
Membuat Font Color dan Font Style



Source Code :

Private Sub chkBold_Click()
If chkBold.Value = 1 Then
lblTeks.FontBold = True
Else
lblTeks.FontBold = False
End If
End Sub

Private Sub chkItalic_Click()
If chkItalic.Value = 1 Then
lblTeks.FontItalic = True
Else
lblTeks.FontItalic = False
End If
End Sub

Private Sub chkStrikeout_Click()
If chkStrikeout.Value = 1 Then
lblTeks.FontStrikethru = True
Else
lblTeks.FontStrikethru = False
End If
End Sub

Private Sub chkUnderline_Click()
If chkUnderline.Value = 1 Then
lblTeks.FontUnderline = True
Else
lblTeks.FontUnderline = False
End If
End Sub

Private Sub cmdExit_Click()
End
End Sub

Private Sub optBlue_Click()
lblTeks.ForeColor = vbBlue
End Sub

Private Sub optGreen_Click()
lblTeks.ForeColor = vbGreen
End Sub

Private Sub optRed_Click()
lblTeks.ForeColor = vbRed
End Sub

Private Sub optYellow_Click()
lblTeks.ForeColor = vbYellow
End Sub

Tugas 2.4

Tugas 2.4
Perhitungan Gaji Menggunakan Keypress


Source Code :

Private Sub cmdKeluar_Click()
End
End Sub

Private Sub cmdProses_Click()
Dim A, B, C, D, E, F As Double
txtD.Text = Val(txtA.Text) + Val(txtB.Text) - Val(txtC.Text)
txtE.Text = Val(txtD.Text) * (0.1)
txtF.Text = Val(txtD.Text) - Val(txtE.Text)
End Sub

Private Sub cmdUlang_Click()
txtA = ""
txtB = ""
txtC = ""
txtD = ""
txtE = ""
txtF = ""
End Sub

Private Sub txtC_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
Dim A, B, C, D, E, F As Double
txtD.Text = Val(txtA.Text) + Val(txtB.Text) - Val(txtC.Text)
txtE.Text = Val(txtD.Text) * (0.1)
txtF.Text = Val(txtD.Text) - Val(txtE.Text)
End If
End Sub

Tugas 2.3

Tugas 2.3
Penghitungan Gaji Tanpa Keypress


Source Code :


Private Sub cmdKeluar_Click()
End
End Sub

Private Sub cmdProses_Click()
Dim A, B, C, D, E, F As Double
txtD.Text = Val(txtA.Text) + Val(txtB.Text) - Val(txtC.Text)
txtE.Text = Val(txtD.Text) * (0.1)
txtF.Text = Val(txtD.Text) - Val(txtE.Text)
End Sub

Private Sub cmdUlang_Click()
txtA = ""
txtB = ""
txtC = ""
txtD = ""
txtE = ""
txtF = ""
End Sub

Tugas 2.2

Tugas 2.2
Perhitungan Mutu Menggunakan Keypress


Source Code :

Private Sub cmdHitung_Click()
Dim A, B, C As Double
txtB.Text = Val(txtA.Text) * 0.1
txtC.Text = Val(txtA.Text) - Val(txtB.Text)
End Sub

Private Sub cmdQuit_Click()
End
End Sub

Private Sub cmdUlang_Click()
txtA = ""
txtB = ""
txtC = ""
End Sub

Private Sub txtB_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
Dim A, B, C As Double
txtB.Text = Val(txtA.Text) * 0.1
txtC.Text = Val(txtA.Text) - Val(txtB.Text)
End If
End Sub

Tugas 2.1

Tugas 2.1
Perhitungan Harga Tanpa Keypress


Source Code :

Private Sub cmdHitung_Click()
Dim A, B, C As Double
txtB.Text = Val(txtA.Text) * 0.1
txtC.Text = Val(txtA.Text) - Val(txtB.Text)
End Sub

Private Sub cmdQuit_Click()
End
End Sub

Private Sub cmdUlang_Click()
txtA = ""
txtB = ""
txtC = ""
End Sub

Selasa, 14 November 2017

Tugas 1.6

Tugas 1.6


HASIL PERHITUNGAN DAPAT KELUAR DENGAN MENEKAN TOMBO COMMAND HITUNG DAN KEYPRESS (TOMBOL ENTER)


 source code:


Private Sub cmdhitung_Click()
txt3 = Val(txt1) + Val(txt2)
txt6 = Val(txt4) / Val(txt5)
txt9 = Val(txt7) - Val(txt8)
txt12 = Val(txt10) * Val(txt11)
End Sub

Private Sub cmdbatal_Click()
txt1 = ""
txt2 = ""
txt3 = ""
txt4 = ""
txt5 = ""
txt6 = ""
txt7 = ""
txt8 = ""
txt9 = ""
txt10 = ""
txt11 = ""
txt12 = ""
txt1.SetFocus
End Sub

Private Sub cmdlagi_Click()
txt1 = ""
txt2 = ""
txt3 = ""
txt4 = ""
txt5 = ""
txt6 = ""
txt7 = ""
txt8 = ""
txt9 = ""
txt10 = ""
txt11 = ""
txt12 = ""
txt1.SetFocus
End Sub

Private Sub cmdkeluar_Click()
Unload Me
End Sub

Private Sub txt1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt2.SetFocus
End If
End Sub

Private Sub txt2_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt4.SetFocus
End If
End Sub

Private Sub txt4_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt5.SetFocus
End If
End Sub

Private Sub txt5_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt7.SetFocus
End If
End Sub

Private Sub txt7_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt8.SetFocus
End If
End Sub

Private Sub txt8_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt10.SetFocus
End If
End Sub

Private Sub txt10_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt11.SetFocus
End If
End Sub

Private Sub txt11_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt3 = Val(txt1) + Val(txt2)
txt6 = Val(txt4) / Val(txt5)
txt9 = Val(txt7) - Val(txt8)
txt12 = Val(txt10) * Val(txt11)
End If
End Sub

Tugas 5

Tugas 5


HASIL PERHITUNGAN DAPAT KELUAR DENGAN MENEKAN TOMBOL COMMAND HITUNG

 source code:


Private Sub cmdhitung_Click()
txt3 = Val(txt1) + Val(txt2)
txt6 = Val(txt4) / Val(txt5)
txt9 = Val(txt7) - Val(txt8)
txt12 = Val(txt10) * Val(txt11)
End Sub

Private Sub cmdbatal_Click()
txt1 = ""
txt2 = ""
txt3 = ""
txt4 = ""
txt5 = ""
txt6 = ""
txt7 = ""
txt8 = ""
txt9 = ""
txt10 = ""
txt11 = ""
txt12 = ""
txt1.SetFocus
End Sub

Private Sub cmdlagi_Click()
txt1 = ""
txt2 = ""
txt3 = ""
txt4 = ""
txt5 = ""
txt6 = ""
txt7 = ""
txt8 = ""
txt9 = ""
txt10 = ""
txt11 = ""
txt12 = ""
txt1.SetFocus
End Sub

Private Sub cmdkeluar_Click()
Unload Me
End Sub

Private Sub txt1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt2.SetFocus
End If
End Sub

Private Sub txt2_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt4.SetFocus
End If
End Sub

Private Sub txt4_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt5.SetFocus
End If
End Sub

Private Sub txt5_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt7.SetFocus
End If
End Sub

Private Sub txt7_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt8.SetFocus
End If
End Sub

Private Sub txt8_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt10.SetFocus
End If
End Sub

Private Sub txt10_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
txt11.SetFocus
End If
End Sub

Tugas Etika Profesi

1.  Pinjaman online adalah fasilitas pinjaman uang oleh penyedia jasa keuangan yang beroperasi secara online. Penyedia pinjaman online terse...