1 / 25

Oleh : Nur Aminudin , S.Kom ., M.T.I NIDN. 0222127602

forbes
Download Presentation

Oleh : Nur Aminudin , S.Kom ., M.T.I NIDN. 0222127602

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Bilamendapat air yang kitatimbadarisumurtampakkeruh, kitaakanmencaritawas (kaporit) untukmenjernihkannya. Demikian pun dalammencariilmu. Kita harusmencariilmu yang bisamenjadi "tawas"-nyasupayakalauhatisudahbening, ilmu-ilmu lain yang kitakajibisadiserapserayamembawamamfaat. Oleh : NurAminudin, S.Kom., M.T.INIDN. 0222127602 STMIK Pringsewu - Lampung

  2. Private Sub cmdBersih_Click() 'MengosongkanisiTextBox txtBil1.Text = "" txtBil2.Text = "" txtHasil.Text = "" End Sub Private Sub cmdHitung_Click() 'DeklarasiVariabelLokal Dim a As Single Dim b As Single Hasil As Single a = txtBil1.Text b = txtBil2.Text Hasil = a * b txtHasil.Text = Hasil End Sub Private Sub cmdKeluar_Click() 'Mengakhiri Program End End Sub

  3. Option Button Control, digunakandalamsuatu group, dimanaseorang user dapatmemilihsalahsatusajadalamsuatu group. Check Box Control, control inidigunakanuntukpilihanya/tidakataubenar/salah.

  4. Private Sub optRed_Click() ‘Membuatteksbewarnamerah lblTeks.ForeColor = vbRed End Sub Private Sub chkBold_Click() ‘MembuatteksTebal If chkBold.Value = 1 Then lblTeks.FontBold = True Else lblTeks.FontBold = False End If End Sub ‘Untukpilihan font color yang ‘lain silakanAndacobamembuat ‘kodeprogramnya ‘Untukpilihan font style yang ‘lain silakanAndabuatkode ‘programnya

  5. 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 cmdUlangi_Click() txtA = "" txtB = "" txtC = "" End Sub

  6. 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

  7. ComboBox Control, control inimerupakangabunganantaraTextBoxdanListBox Control, dimanadaftar item hanyaakanditampilkanjika user men-click padapanahkebawahdisebelahkanan Control tersebut

  8. Private Sub Cbonpm_Click() Dim nama, jurusan, HM As String Select Case Cbonpm.Text Case "09100027" nama = "AFNAN ZALFA SALSABILA A" jurusan = "SistemInformasi" Case "09200048" nama = "AMALIA AMANAH" jurusan = "ManajemenInformatika" Case "09300024" nama = "SASKIA MECHA" jurusan = "TehnikInformatika" End Select txtnama.Text = nama txtjurusan.Text = jurusan txtquis.SetFocus End Sub

  9. Private Sub Cmdbatal_Click() Cbonpm.SetFocus Cbonpm.Text = "" txtnama.Text = "" txtjurusan.Text = "" txtquis.Text = "" txttugas.Text = "" txtuts.Text = "" txtuas.Text = "" txtna.Text = "" txthm.Text = "" End Sub Private Sub Cmdkeluar_Click() Unload Me End Sub

  10. Private Sub Cmdproses_Click() Dim NA As Integer Dim HM As String QUIS = Val(txtquis.Text) TUGAS = Val(txttugas.Text) UTS = Val(txtuts.Text) UAS = Val(txtuas.Text) NA = (QUIS + TUGAS + UTS + UAS) / 4 txtna.Text = NA Select Case txtna.Text Case Is > 80 HM = "A" Case Is > 70 HM = "B" Case Is > 60 HM = "C" Case Is > 50 HM = "D" Case Is < 50 HM = "E" End Select txthm.Text = HM End Sub

  11. Private Sub Form_Load() Cbonpm.AddItem "09100027" Cbonpm.AddItem "09200048" Cbonpm.AddItem "09300024" End Sub Private Sub txtquis_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then txttugas.SetFocus End If End Sub Private Sub txttugas_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then txtuts.SetFocus End If End Sub Private Sub txtuts_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then txtuas.SetFocus End If End Sub

  12. Private Sub Command1_Click() Label2.Caption = Text1.Text End Sub Private Sub Command2_Click() End End Sub Private Sub Option1_Click() Label2.ForeColor = vbBlue End Sub Private Sub Option2_Click() Label2.ForeColor = vbRed End Sub Private Sub Check1_Click() Label2.FontBold = Check1.Value End Sub Private Sub Check2_Click() Label2.FontItalic = Check2.Value End Sub

  13. Private Sub Cmdbatal_Click() kosong End Sub Private Sub cmdlagi_Click() kosong End Sub Private Sub Form_load() cbogolongan.AddItem "I" cbogolongan.AddItem "II" cbogolongan.AddItem "III" cbogolongan.AddItem "IV" End Sub Private Sub Cmdkeluar_Click() Unload Me End Sub

  14. Private Sub cbogolongan_Click() Dim gapok, pajak, tunjangan, total As Variant Select Case cbogolongan.Text Case "I" gapok = 1500000 tunjangan = 150000 Case "II" gapok = 2000000 tunjangan = 200000 Case "III" gapok = 2500000 tunjangan = 250000 Case "IV" gapok = 3000000 tunjangan = 300000 Case Else gapok = 0 tunjangan = 0 End Select total = gapok + tunjangan pajak = total * 0.1 txtgapok.Text = gapok txttunjangan.Text = tunjangan txtpajak.Text = pajak txttotal.Text = total - pajak End Sub

  15. Public Sub kosong() txtnidn.SetFocus txtnidn.Text = "" txtnama.Text = "" cbogolongan.Text = "" txtgapok.Text = "" txttunjangan.Text = "" txtpajak.Text = "" txttotal.Text = "" End Sub Private Sub txtnind_keypress(keyascii As Integer) If keyascii = 13 Then txtnama.SetFocus End If End Sub

  16. Private Sub Cmdbatal_Click() Txtnama.SetFocus Txtnama.Text = "" Txtnpm.Text = "" Txtjur.Text = "" Txtps.Text = "" TxtTm.Text = "" Txturut.Text = "" End Sub Private Sub Cmdkeluar_Click() Unload Me End Sub Private Sub Cmdlagi_Click() Txtnama.SetFocus Txtnama.Text = "" Txtnpm.Text = "" Txtjur.Text = "" Txtps.Text = "" TxtTm.Text = "" Txturut.Text = "" End Sub

  17. Private Sub Cmdproses_Click() Dim S As String TxtTm.Text = "20" & Left(Txtnpm.Text, 2) S = Mid(Txtnpm.Text, 3, 1) If S = "1" Then Txtjur.Text = "SistemInformasi" ElseIf S = "2" Then Txtjur.Text = "ManajemenInformatika" ElseIf S = "3" Then Txtjur.Text = "TehnikInformatika" ElseIf S = "4" Then Txtjur.Text = "Manajemen & Komp. Akuntansi" End If S = Mid(Txtnpm.Text, 4, 2) If S = "01" Then Txtps.Text = "Strata Satu" ElseIf S = "02" Then Txtps.Text = "Diploma Tiga" ElseIf S = "03" Then Txtps.Text = "Diploma Empat" ElseIf S = "04" Then Txtps.Text = "Diploma Dua" End If Txturut.Text = Right(Txtnpm.Text, 3) End Sub

  18. Private Sub Form_activate() Txtnama.SetFocus Txtnama.Text = "" Txtnpm.Text = "" Txtjur.Text = "" Txtps.Text = "" TxtTm.Text = "" Txturut.Text = "" End Sub Private Sub Txtnama_Keypress(Keyascii As Integer) If Keyascii = 13 Then Txtnpm.SetFocus End If End Sub

More Related