DATA BASE DBGRID 9 PROGRAM

1. DATA BUKU

  1. DATA BUKU

 

 

Private Sub CmdB_Click()

Data1.Recordset.AddNew

End Sub

 

Private Sub CmdH_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdBatal_Click()

CboKode.SetFocus

CboKode.Text = “Kode”

TxtJudulBuku.Text = “”

TxtPeng.Text = “”

TxtTahunTer.Text = “”

TxtPenerbit.Text = “”

TxtHarga.Text = “”

End Sub

 

Private Sub CmdEnd_Click()

Form2.Show

End Sub

 

Private Sub CmdLagi_Click()

CboKode.SetFocus

CboKode.Text = “Kode”

TxtJudulBuku.Text = “”

TxtPeng.Text = “”

TxtTahunTer.Text = “”

TxtPenerbit.Text = “”

TxtHarga.Text = “”

End Sub

 

Private Sub CmdProses_Click()

Dim JudulB, Peng, Pen, Hg As String

TxtTahunTer.Text = “20” & Right(CboKode, 2)

s = Mid(CboKode, 3, 3)

If s = “SIM” Then

JudulB = “Sistem Informasi Manajemen”

Peng = “Yati Nur Oktavia”

Hg = “75900”

 

ElseIf s = “EDP” Then

JudulB = “Elektronik Data Processing”

Peng = “Imam Tarmizi”

Hg = “62000”

 

ElseIf s = “MNJ” Then

JudulB = “Manajemen”

Peng = “Valentina Mariana Adiwianti”

Hg = “42000”

 

ElseIf s = “CDR” Then

JudulB = “Corel Draw”

Peng = “Riyan Suhandi”

Hg = “53000”

 

ElseIf s = “RPL” Then

JudulB = “Rekayasa Perangkat Lunak”

Peng = “Sinta Umpu Singa”

Hg = “83000”

End If

TxtJudulBuku = JudulB

TxtPeng = Peng

TxtHarga = Hg

s = Mid(CboKode, 1, 1)

If s = “A” Then

Pen = “Andi Offset Yogyakarta”

ElseIf s = “I” Then

Pen = “Indah Surabaya”

ElseIf s = “S” Then

Pen = “Salemba Empat”

ElseIf s = “E” Then

Pen = “Elek Media Komputindo”

ElseIf s = “M” Then

Pen = “Maxicom”

End If

TxtPenerbit.Text = Pen

End Sub

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

 

Private Sub Form_Load()

CboKode.AddItem “A-SIM-01”

CboKode.AddItem “I-EDP-02”

CboKode.AddItem “S-MNJ-03”

CboKode.AddItem “E-CDR-04”

CboKode.AddItem “M-RPL-05”

End Sub

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

 

 

2. NIDN

2. NIDN

 

 

Private Sub CmbGolongan_Click()

Dim Gapok, Pajak, Tunjangan, Total As Variant

Select Case CmbGolongan.Text

Case “I”

Gapok = 1900000

Tunjangan = 130000

Case “II”

Gapok = 2000000

Tunjangan = 200000

Case “III”

Gapok = 2900000

Tunjangan = 290000

Case “IV”

Gapok = 3000000

Tunjangan = 300000

Case Else

Gapok = 0

Tunjangan = 0

End Select

Total = Gapok + Tunjangan

Pajak = Total * 0.1

TxtGapok.Text = Gapok

TxtTj.Text = Tunjangan

TxtPajak.Text = Pajak

TxtTotal.Text = Total – Pajak

End Sub

 

Private Sub CmdB_Click()

Data1.Recordset.AddNew

TxtNidn.SetFocus

End Sub

 

Private Sub CmdBatal_Click()

TxtNidn.SetFocus

TxtNidn = “”

TxtNamaP = “”

CmbGolongan = “Golongan”

TxtGapok = “”

TxtPajak = “”

TxtTj = “”

TxtTotal = “”

End Sub

 

Private Sub CmdH_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdKeluar_Click()

Form2.Show

End Sub

 

Private Sub CmdLagi_Click()

TxtNidn.SetFocus

TxtNidn = “”

TxtNamaP = “”

CmbGolongan = “Golongan”

TxtGapok = “”

TxtPajak = “”

TxtTj = “”

TxtTotal = “”

End Sub

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

 

Private Sub Form_Load()

CmbGolongan.AddItem “I”

CmbGolongan.AddItem “II”

CmbGolongan.AddItem “III”

CmbGolongan.AddItem “IV”

End Sub

 

Private Sub TxtNidn_keypress(keyascii As Integer)

If keyascii = 13 Then

TxtNamaP.SetFocus

End If

End Sub

 

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

 

3. DATA SISWA

 

 

3. DATA SISWA

 

 

Private Sub CmdB_Click()

Data1.Recordset.AddNew

TxtNm.SetFocus

End Sub

 

Private Sub CmdHapus_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdLagi_Click()

TxtNm.SetFocus

TxtNm = “”

TxtNpm = “”

TxtJr = “”

TxtPStudi = “”

TxtTMasuk = “”

TxtNUrut = “”

End Sub

 

Private Sub CmdPr_Click()

Dim Ket As String

Ket = Mid(TxtNpm.Text, 3, 1)

If Ket = “1” Then

TxtJr.Text = “Sistem Informasi”

ElseIf Ket = “2” Then

TxtJr.Text = “Manajemen Informatika”

ElseIf Ket = “3” Then

TxtJr.Text = “Tehnik Informatika”

ElseIf Ket = “4” Then

TxtJr.Text = “Manajemen & Komp. Akuntansi”

End If

Ket = Mid(TxtNpm.Text, 4, 2)

If Ket = “00” Then

TxtPStudi.Text = “Strata Satu”

ElseIf Ket = “01” Then

TxtPStudi.Text = “Diploma Tiga”

ElseIf Ket = “02” Then

TxtPStudi.Text = “Diploma Empat”

ElseIf Ket = “03” Then

TxtPStudi.Text = “Diploma Dua”

End If

TxtNUrut.Text = Right(TxtNpm.Text, 3)

TxtTMasuk.Text = “20” & Left(TxtNpm.Text, 2)

 

End Sub

 

Private Sub CmdBatal_Click()

TxtNm.SetFocus

TxtNm = “”

TxtNpm = “”

TxtJr = “”

TxtPStudi = “”

TxtTMasuk = “”

TxtNUrut = “”

End Sub

 

Private Sub CmdEnd_Click()

Form2.Show

End Sub

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

 

Private Sub TxtNm_keypress(keyascii As Integer)

If keyascii = 13 Then

TxtNpm.SetFocus

End If

End Sub

 

Private Sub TxtNpm_keypress(keyascii As Integer)

If keyascii = 13 Then

Dim Ket As String

Ket = Mid(TxtNpm.Text, 3, 1)

If Ket = “1” Then

TxtJr.Text = “Sistem Informasi”

ElseIf Ket = “2” Then

TxtJr.Text = “Manajemen Informatika”

ElseIf Ket = “3” Then

TxtJr.Text = “Tehnik Informatika”

ElseIf Ket = “4” Then

Txtjur.Text = “Manajemen & Komp. Akuntansi”

End If

Ket = Mid(TxtNpm.Text, 4, 2)

If Ket = “00” Then

TxtPStudi.Text = “Strata Satu”

ElseIf Ket = “01” Then

TxtPStudi.Text = “Diploma Tiga”

ElseIf Ket = “02” Then

TxtPStudi.Text = “Diploma Empat”

ElseIf Ket = “03” Then

TxtPStudi.Text = “Diploma Dua”

End If

TxtNUrut.Text = Right(TxtNpm.Text, 3)

TxtTMasuk.Text = “20” & Left(TxtNpm.Text, 2)

End If

End Sub

 

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

 

4. entri penjualan laptop apple

 

4. ENTRI PENJUALAN LAPTOP APPLE

 

Private Sub CboKode_Click()

TxtJJual.SetFocus

Dim Merk, Satuan As Variant

Select Case CboKode.Text

Case “Apple MC965 MacBook Air”

Merk = “Apple MacBook Air MC965”

Satuan = 12800000

Case “Apple MC966 MacBook Air”

Merk = “Apple MacBook Air MC966”

Satuan = 15800000

Case “Apple MC968 MacBook Air”

Merk = “Apple MacBook Air MC965”

Satuan = 9900000

Case “Apple MC969 MacBook Air”

Merk = “Apple MacBook Air MC969”

Satuan = 11900000

Case “Apple MC700 MacBook Pro”

Merk = “Apple MacBook Pro MC700”

Satuan = 10800000

Case “Apple MC721 MacBook Pro”

Merk = “Apple MacBook Pro MC721”

Satuan = 15900000

Case “Apple MC723 MacBook Pro”

Merk = “Apple MacBook Pro MC723”

Satuan = 19300000

Case “Apple MC724 MacBook Pro”

Merk = “Apple MacBook Pro MC724”

Satuan = 13700000

Case “Apple MC311 MacBook Pro”

Merk = “Apple MacBook Pro MC311”

Satuan = 24200000

Case “Apple MC313 MacBook Pro”

Merk = “Apple MacBook Pro MC313”

Satuan = 11900000

Case “Apple MC314 MacBook Pro”

Merk = “Apple MacBook Pro MC314”

Satuan = 14700000

Case “Apple MC318 MacBook Pro”

Merk = “Apple MacBook Pro MC318”

Satuan = 17600000

Case “Apple MC322 MacBook Pro”

Merk = “Apple MacBook Pro MC322”

Satuan = 21300000

Case “Apple MC965 MacBook Air”

Merk = “Apple MacBook Air MC965”

Satuan = 12800000

Case “Apple MC966 MacBook Air”

Merk = “Apple MacBook Air MC966”

Satuan = 15800000

End Select

TxtMerk.Text = Merk

TxtHS.Text = Satuan

 

End Sub

 

 

Private Sub CmdE_Click()

Data1.Recordset.Edit

End Sub

 

Private Sub CmdH_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdHL_Click()

CboKode.SetFocus

CboKode = “Kode Laptop”

TxtMerk = “”

TxtHS = “”

TxtTotal = “”

TxtHargaPen = “”

TxtDis = “”

TxtTotal = “”

TxtJJual = “”

End Sub

 

Private Sub CmdKeluar_Click()

Form2.Show

End Sub

 

Private Sub CmdProses_Click()

TxtHargaPen = Val(TxtHS) * Val(TxtJJual)

 

If Val(TxtHargaPen) > 140000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.15

Else

 

If Val(TxtHargaPen) > 135000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.1

Else

 

If Val(TxtHargaPen) > 130000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.05

Else

 

If Val(TxtHargaPen) > 125000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.02

Else

 

If Val(TxtHargaPen) <= 125000000 Then

TxtDis = “0”

End If

End If

End If

End If

End If

TxtTotal = Val(TxtHargaPen) – Val(TxtDis)

End Sub

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdY_Click()

Data1.Recordset.AddNew

 

End Sub

 

Private Sub Form_Load()

CboKode.AddItem “Apple MC965 MacBook Air”

CboKode.AddItem “Apple MC966 MacBook Air”

CboKode.AddItem “Apple MC968 MacBook Air”

CboKode.AddItem “Apple MC969 MacBook Air”

CboKode.AddItem “Apple MC700 MacBook Pro”

CboKode.AddItem “Apple MC721 MacBook Pro”

CboKode.AddItem “Apple MC723 MacBook Pro”

CboKode.AddItem “Apple MC724 MacBook Pro”

CboKode.AddItem “Apple MC311 MacBook Pro”

CboKode.AddItem “Apple MC313 MacBook Pro”

CboKode.AddItem “Apple MC314 MacBook Pro”

CboKode.AddItem “Apple MC318 MacBook Pro”

CboKode.AddItem “Apple MC322 MacBook Pro”

CboKode.AddItem “Apple MC965 MacBook Air”

CboKode.AddItem “Apple MC966 MacBook Air”

End Sub

 

Private Sub TxtJJual_keypress(keyascii As Integer)

If keyascii = 13 Then

TxtHargaPen = Val(TxtHS) * Val(TxtJJual)

 

If Val(TxtHargaPen) > 140000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.15

Else

 

If Val(TxtHargaPen) > 135000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.1

Else

 

If Val(TxtHargaPen) > 130000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.05

Else

 

If Val(TxtHargaPen) > 125000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.02

Else

 

If Val(TxtHargaPen) <= 125000000 Then

TxtDis = “0”

End If

End If

End If

End If

End If

TxtTotal = Val(TxtHargaPen) – Val(TxtDis)

End If

End Sub

 

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

5. ENTRI PENJUALAN KOMPUTER

 

5. ENTRI PENJUALAN KOMPUTER

 

Private Sub CboKode_Click()

Dim JK, HS, HB As Integer

Select Case CboKode.Text

Case “P205”

JK = “Pentium II 500 Mega Hz”

HS = “1500000”

Case “P308”

JK = “Pentium III 800 Mega Hz”

HS = “2100000”

Case “P310”

JK = “Pentium III 1.0 Giga Hz”

HS = “3500000”

Case “P415”

JK = “Pentium IV 1.5 Giga Hz”

HS = “4000000”

Case “P417”

JK = “Pentium IV 1.7 Giga Hz”

HS = “4200000”

Case “P419”

JK = “Pentium IV 1.9 Giga Hz”

HS = “5500000”

End Select

TxtJCom = JK

TxtHS = HS

TxtJJual.SetFocus

End Sub

 

 

Private Sub CmdB_Click()

Data1.Recordset.AddNew

End Sub

 

Private Sub CmdH_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdKeluar_Click()

Form2.Show

End Sub

 

Private Sub CmdLagi_Click()

CboKode.SetFocus

CboKode = “Kode”

TxtJCom = “”

TxtHS = “”

TxtJJual = “”

TxtHargaPen = “”

TxtDis = “”

TxtTotal = “”

 

End Sub

 

Private Sub CmdProses_Click()

TxtHargaPen.Text = Val(TxtHS) * Val(TxtJJual)

If Val(TxtHargaPen) > 30000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.15

Else

If Val(TxtHargaPen) > 25000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.1

Else

If Val(TxtHargaPen) > 20000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.05

Else

If Val(TxtHargaPen) > 15000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.02

 

ElseIf Val(TxtHargaPen) <= 15000000 Then

TxtDis = “0”

End If

End If

End If

End If

TxtTotal = Val(TxtHargaPen) – Val(TxtDis)

End Sub

 

 

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

 

Private Sub Form_Load()

CboKode.AddItem “P205”

CboKode.AddItem “P308”

CboKode.AddItem “P310”

CboKode.AddItem “P415”

CboKode.AddItem “P417”

CboKode.AddItem “P419”

 

End Sub

 

Private Sub TxtJJual_Keypress(keyascii As Integer)

If keyascii = 13 Then

TxtHargaPen.Text = Val(TxtHS) * Val(TxtJJual)

If Val(TxtHargaPen) > 30000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.15

Else

If Val(TxtHargaPen) > 25000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.1

Else

If Val(TxtHargaPen) > 20000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.05

Else

If Val(TxtHargaPen) > 15000000 Then

TxtDis = Val(TxtHargaPen.Text) * 0.02

 

ElseIf Val(TxtHargaPen) <= 15000000 Then

TxtDis = “0”

End If

End If

End If

End If

End If

TxtTotal = Val(TxtHargaPen) – Val(TxtDis)

End Sub

 

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

 

6. PENJUALAN TIKET KERETA

 

6. PENJUALAN TIKET KERETA API

 

Private Sub CmdB_Click()

Data1.Recordset.AddNew

End Sub

 

Private Sub CmdH_Click()

Data1.Recordset.MoveLast

Data1.Recordset.Delete

End Sub

 

Private Sub CmdKeluar_Click()

Form2.Show

End Sub

Private Sub CmdLagi_Click()

TxtKt.SetFocus

TxtKt.Text = “”

TxtHt.Text = “”

TxtJk.Text = “”

TxtJb.Text = “”

TxtJt.Text = “”

TxtTotalP.Text = “”

End Sub

Private Sub CmdProses_Click()

Dim Jk, Ht, Jb As String

I = Left(TxtKt, 3)

If I = “BIM” Then

Jk = “BIMA”

Ht = “50000”

Jb = “16.00”

 

ElseIf I = “EKO” Then

Jk = “EKONOMI”

Ht = “35000”

Jb = “19.00”

ElseIf I = “MUT” Then

Jk = “MUTIARA”

Ht = “23000”

Jb = “17.00”

ElseIf I = “SEN” Then

Jk = “SENJA”

Ht = “15000”

Jb = “20.00”

End If

TxtJk = Jk

TxtHt = Ht

TxtJb = Jb

TxtJt.SetFocus

End Sub

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

 

 

Private Sub TxtJt_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

TxtTotalP = Val(TxtHt) * Val(TxtJt)

End If

End Sub

 

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

 

7. DATA BUKU STMIK 2

7. DATA BUKU STMIK 2

 

Private Sub CmdBatal_Click()

TxtKodeBuku.SetFocus

TxtKodeBuku = “”

TxtJudulBuku = “”

TxtPeng = “”

TxtTahunTer = “”

TxtPenerbit = “”

TxtHarga = “”

End Sub

 

Private Sub CmdEnd_Click()

Form2.Show

End Sub

 

Private Sub CmdLagi_Click()

TxtKodeBuku.SetFocus

TxtKodeBuku = “”

TxtJudulBuku = “”

TxtPeng = “”

TxtTahunTer = “”

TxtPenerbit = “”

TxtHarga = “”

End Sub

 

Private Sub CmdProses_Click()

Dim JudulB, Peng, Pen, Hg As Variant

TxtTahunTer.Text = “20” & Mid(TxtKodeBuku, 5, 2)

s = Left(TxtKodeBuku, 3)

If s = “SIM” Then

JudulB = “Sistem Informasi Manajemen”

Peng = “Fadiya Ulfa”

Hg = “75900”

 

ElseIf s = “EDP” Then

JudulB = “Elektronik Data Processing”

Peng = “Nurul Agustina”

Hg = “62000”

 

ElseIf s = “MNJ” Then

JudulB = “Manajemen”

Peng = “Rian Hidayat”

Hg = “42000”

 

ElseIf s = “CDR” Then

JudulB = “Corel Draw”

Peng = “Siti Nur Khotimah”

Hg = “53000”

 

ElseIf s = “RPL” Then

JudulB = “Rekayasa Perangkat Lunak”

Peng = “Winda Erlianti”

Hg = “83000”

End If

TxtJudulBuku = JudulB

TxtPeng = Peng

TxtHarga = Hg

 

s = Right(TxtKodeBuku, 1)

If s = “A” Then

Pen = “Andi Offset Yogyakarta”

ElseIf s = “I” Then

Pen = “Indah Surabaya”

ElseIf s = “S” Then

Pen = “Salemba Empat”

ElseIf s = “E” Then

Pen = “Elek Media Komputindo”

ElseIf s = “M” Then

Pen = “Maxicom”

End If

TxtPenerbit.Text = Pen

End Sub

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

Private Sub CmdB_Click()

Data1.Recordset.AddNew

End Sub

Private Sub CmdH_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub TxtKodeBuku_keypress(keyascii As Integer)

If keyascii = 13 Then

Dim JudulB, Peng, Pen, Hg As Variant

TxtTahunTer.Text = “20” & Mid(TxtKodeBuku, 5, 2)

s = Left(TxtKodeBuku, 3)

If s = “SIM” Then

JudulB = “Sistem Informasi Manajemen”

Peng = “Fadiya Ulfa”

Hg = “75900”

 

ElseIf s = “EDP” Then

JudulB = “Elektronik Data Processing”

Peng = “Nurul Agustina”

Hg = “62000”

 

ElseIf s = “MNJ” Then

JudulB = “Manajemen”

Peng = “Rian Hidayat”

Hg = “42000”

 

ElseIf s = “CDR” Then

JudulB = “Corel Draw”

Peng = “Siti Nur Khotimah”

Hg = “53000”

 

ElseIf s = “RPL” Then

JudulB = “Rekayasa Perangkat Lunak”

Peng = “Winda Erlianti”

Hg = “83000”

End If

TxtJudulBuku = JudulB

TxtPeng = Peng

TxtHarga = Hg

 

s = Right(TxtKodeBuku, 1)

If s = “A” Then

Pen = “Andi Offset Yogyakarta”

ElseIf s = “I” Then

Pen = “Indah Surabaya”

ElseIf s = “S” Then

Pen = “Salemba Empat”

ElseIf s = “E” Then

Pen = “Elek Media Komputindo”

ElseIf s = “M” Then

Pen = “Maxicom”

End If

TxtPenerbit.Text = Pen

End If

End Sub

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

 

 

8. PT PULANG PETANG

 

 

8. PT PULANG PETANG

 

Private Sub CmdS_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

Data1.Recordset.MoveLast

End Sub

Private Sub CmdB_Click()

Data1.Recordset.AddNew

TxtNamaKar.SetFocus

End Sub

Private Sub CmdH_Click()

Data1.Recordset.Delete

Data1.Recordset.MoveLast

End Sub

 

Private Sub CmdBatal_Click()

TxtNamaKar.SetFocus

TxtNamaKar = “”

TxtNik = “”

TxtGol = “”

TxtKode = “”

TxtStatus = “”

TxtTahun = “”

TxtJabatan = “”

TxtProf = “”

TxtGapok = “”

TxtTunj = “”

TxtTotalG = “”

End Sub

Private Sub CmdKeluar_Click()

Form2.Show

End Sub

Private Sub CmdLagi_Click()

TxtNamaKar.SetFocus

TxtNamaKar = “”

TxtNik = “”

TxtGol = “”

TxtKode = “”

TxtStatus = “”

TxtTahun = “”

TxtJabatan = “”

TxtProf = “”

TxtGapok = “”

TxtTunj = “”

TxtTotalG = “”

End Sub

Private Sub CmdProses_Click()

Dim S As String

TxtTahun.Text = Left(TxtNik, 4)

S = Mid(TxtNik, 5, 1)

If S = “A” Then

TxtGol = “A”

TxtJabatan = “Manager”

TxtGapok = “4000000”

TxtTunj = “1025000”

ElseIf S = “B” Then

TxtGol = “B”

TxtJabatan = “Ka. Seksi”

TxtGapok = “3500000”

TxtTunj = “975000”

ElseIf S = “C” Then

TxtGol = “C”

TxtJabatan = “Staff”

TxtGapok = “3000000”

TxtTunj = “925000”

End If

S = Right(TxtNik, 3)

If S = “KEU” Then

TxtProf = “Accounting”

ElseIf S = “ADM” Then

TxtProf = “Administrasi”

ElseIf S = “SDM” Then

TxtProf = “General Affair”

ElseIf S = “EDP” Then

TxtProf = “IT Unit”

ElseIf S = “SPM” Then

TxtProf = “Security”

End If

S = Mid(TxtNik, 7, 1)

If S = “S” Then

TxtKode.Text = “S”

TxtStatus.Text = “Single”

ElseIf S = “M” Then

TxtKode.Text = “M”

TxtStatus.Text = “Menikah”

ElseIf S = “J” Then

TxtKode.Text = “J”

TxtStatus.Text = “Janda”

ElseIf S = “D” Then

TxtKode.Text = “D”

TxtStatus.Text = “Duda”

End If

TxtTotalG = Val(TxtGapok) + Val(TxtTunj)

End Sub

 

Private Sub TxtNamaKar_KeyPress(keyascii As Integer)

If keyascii = 13 Then

TxtNik.SetFocus

End If

End Sub

Private Sub TxtNik_Keypress(keyascii As Integer)

If keyascii = 13 Then

If keyascii = 13 Then

Dim S As String

TxtTahun.Text = Left(TxtNik, 4)

S = Mid(TxtNik, 5, 1)

If S = “A” Then

TxtGol = “A”

TxtJabatan = “Manager”

TxtGapok = “4000000”

TxtTunj = “1025000”

ElseIf S = “B” Then

TxtGol = “B”

TxtJabatan = “Ka. Seksi”

TxtGapok = “3500000”

TxtTunj = “975000”

ElseIf S = “C” Then

TxtGol = “C”

TxtJabatan = “Staff”

TxtGapok = “3000000”

TxtTunj = “925000”

End If

S = Right(TxtNik, 3)

If S = “KEU” Then

TxtProf = “Accounting”

ElseIf S = “ADM” Then

TxtProf = “Administrasi”

ElseIf S = “SDM” Then

TxtProf = “General Affair”

ElseIf S = “EDP” Then

TxtProf = “IT Unit”

ElseIf S = “SPM” Then

TxtProf = “Security”

End If

S = Mid(TxtNik, 7, 1)

If S = “S” Then

TxtKode.Text = “S”

TxtStatus.Text = “Single”

ElseIf S = “M” Then

TxtKode.Text = “M”

TxtStatus.Text = “Menikah”

ElseIf S = “J” Then

TxtKode.Text = “J”

TxtStatus.Text = “Janda”

ElseIf S = “D” Then

TxtKode.Text = “D”

TxtStatus.Text = “Duda”

End If

TxtTotalG = Val(TxtGapok) + Val(TxtTunj)

End If

End If

End Sub

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

 

Private Sub CmdY_Click()

End

End Sub

 

 

9. DATA BASE

 

9. TOKO ALAT TULIS SALSABILA

 

Private Sub CmdProses_Click()

Dim Kode As Variant

Kode = Mid(Txtkode.Text, 5, 2)

If Kode = “SP” Then

TxtNb.Text = “Spidol”

TxtHb.Text = “9500”

ElseIf Kode = “BT” Then

TxtNb.Text = “Buku Tulis”

TxtHb.Text = “12500”

ElseIf Kode = “TP” Then

TxtNb.Text = “TIP EX”

TxtHb.Text = “3000”

ElseIf Kode = “PG” Then

TxtNb.Text = “PENGGARIS”

TxtHb.Text = “25000”

ElseIf Kode = “PT” Then

TxtNb.Text = “PAPAN TULIS”

TxtHb.Text = “50000”

End If

TxtJb.SetFocus

End Sub

 

Private Sub TxtAdd_Click()

Data1.Recordset.AddNew

End Sub

 

Private Sub TxtHitung_Click()

TxtBr = Val(TxtHb) * Val(TxtJb)

If Val(TxtJb) > 5 Then

TxtPot = Val(TxtBr.Text) * 0.02

ElseIf Val(TxtJb.Text) <= 5 Then

TxtPot = “0”

End If

TxtTb = Val(TxtBr) – Val(TxtPot)

End Sub

 

Private Sub TxtKeluar_Click()

Form2.Show

 

End Sub

 

Private Sub Txtkode_Change()

 

End Sub

 

Private Sub TxtSave_Click()

Data1.Recordset.AddNew

Data1.Recordset.Update

End Sub

 

Private Sub CmdN_Click()

Form1.Show

Form2.Hide

End Sub

 

Private Sub CmdY_Click()

End

End Sub

Advertisements

TUGAS 8 PROGRAM VISUAL BASIC

TUGAS 1

tugas 1

 

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

 

Private Sub Cmdbatal_Click()

cogolongan = “”

txtnidn = “”

Txtnama = “”

Txtgapok = “”

Txttunjangan = “”

Txtpajak = “”

Txttotal = “”

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdlagi_Click()

txtnidn = “”

Txtnama = “”

cogolongan = “”

Txtgapok = “”

Txttunjangan = “”

Txtpajak = “”

Txttotal = “”

End Sub

 

Private Sub Form_Load()

Cbogolongan.AddItem “I”

Cbogolongan.AddItem “II”

Cbogolongan.AddItem “III”

Cbogolongan.AddItem “IV”

End Sub

Private Sub txtnidn_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Txtnama.SetFocus

End If

End Sub

 

 

TUGAS 2

 

2

 

Private Sub Cmdbatal_Click()

txtnama.SetFocus

txtnama.Text = “”

txtnpm.Text = “”

txtjurusan.Text = “”

txtprodi.Text = “”

txttm.Text = “”

txtnu.Text = “”

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdlagi_Click()

txtnama.SetFocus

txtnama.Text = “”

txtnpm.Text = “”

txtjurusan.Text = “”

txtprodi.Text = “”

txttm.Text = “”

txtnu.Text = “”

End Sub

 

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

txtjurusan.Text = “Sistem Informasi”

txtprodi.Text = “Strata Satu”

ElseIf S = “2” Then

txtjurusan.Text = “Manajemen Informatika”

txtprodi.Text = “Diploma Tiga”

ElseIf S = “3” Then

txtjurusan.Text = “Tehnik Informatika”

txtprodi.Text = “Diploma Empat”

ElseIf S = “4” Then

txtjurusan.Text = “Komputer Akuntansi”

txtprodi.Text = “Diploma Dua”

End If

txtnu.Text = Right(txtnpm.Text, 5)

End Sub

 

 

Private Sub txtnama_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

txtnpm.SetFocus

End If

End Sub

Private Sub txtnpm_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Dim S As String

txttm.Text = “20” & Left(txtnpm.Text, 2)

S = Mid(txtnpm.Text, 3, 1)

If S = “1” Then

txtjurusan.Text = “Sistem Informasi”

txtprodi = “Strata Satu”

ElseIf S = “2” Then

txtjurusan.Text = “Teknik Informatika”

txtprodi = “Diplomat Empat”

ElseIf S = “3” Then

txtjurusan.Text = “Manajemen Informatika”

txtprodi = “Diploma Tiga”

ElseIf S = “4” Then

txtjurusan.Text = “Komputer Akuntansi”

txtprodi = “Diploma Dua”

End If

txtnu.Text = Right(txtnpm.Text, 5)

End If

End Sub

 

 

TUGAS 3

ENTRI PENJUALAN LAPTOP APPLE

entri penjualan laptop T3

Private Sub cbokode_Click()

Select Case cbokode.Text

Case Is = “Apple MC956 MacBook Air”

MERK = “Apple MC956 MacBook Air”

HS = “12800000”

Case Is = “Apple MC966 MacBook Air”

MERK = “Apple MC966 MacBook Air”

HS = “15800000”

Case Is = “Apple MC968 MacBook Air”

MERK = “Apple MC968 MacBook Air”

HS = “9900000”

Case Is = “Apple MC969 MacBook Air”

MERK = “Apple MC969 MacBook Air”

HS = “11900000”

Case Is = “Apple MC700 MacBook Pro”

MERK = “Apple MC700 MacBook Pro”

HS = “10800000”

Case Is = “Apple MC721 MacBook Pro”

MERK = “Apple MC721 MacBook Pro”

HS = “15900000”

Case Is = “Apple MC723 MacBook Pro”

MERK = “Apple MC723 MacBook Pro”

HS = “19300000”

Case Is = “Apple MC724 MacBook Pro”

MERK = “Apple MC724 MacBook Pro”

HS = “13700000”

Case Is = “Apple MC711 MacBook Pro”

MERK = “Apple MC711 MacBook Pro”

HS = “24200000”

Case Is = “Apple MC313 MacBook Pro”

MERK = “Apple MC313 MacBook Pro”

HS = “11900000”

Case Is = “Apple MC314 MacBook Pro”

MERK = “Apple MC314 MacBook Pro”

HS = “14700000”

Case Is = “Apple MC318 MacBook Pro”

MERK = “Apple MC318 MacBook Pro”

HS = “17600000”

Case Is = “Apple MC322 MacBook Pro”

MERK = “Apple MC322 MacBook Pro”

HS = “21300000”

Case Is = “Apple MC965 MacBook Air”

MERK = “Apple MC965 MacBook Air”

HS = “12800000”

Case Is = “Apple MC966 MacBook Air”

MERK = “Apple MC966 MacBook Air”

HS = “15800000”

End Select

txtmerk.Text = MERK

Txths.Text = HS

Txtjj.SetFocus

End Sub

 

Private Sub Cmdhitunglagi_Click()

cbokode.SetFocus

cbokode.Text = “”

txtmerk.Text = “”

Txths.Text = “”

Txtjj.Text = “”

Txthp.Text = “”

Txtdis.Text = “”

Txttb.Text = “”

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdproses_Click()

Txthp.Text = Val(Txths.Text) * Val(Txtjj.Text)

Select Case Txthp.Text

Case Is > 140000000

discount = Val(Txthp.Text) * 0.15

Case Is > 135000000

discount = Val(Txthp.Text) * 0.1

Case Is > 130000000

discount = Val(Txthp.Text) * 0.05

Case Is > 125000000

discount = Val(Txthp.Text) * 0.02

End Select

Txtdis.Text = discount

Txttb.Text = Val(Txthp.Text) – Val(Txtdis.Text)

End Sub

 

Private Sub Form_Load()

cbokode.AddItem “Apple MC956 MacBook Air”

cbokode.AddItem “Apple MC966 MacBook Air”

cbokode.AddItem “Apple MC968 MacBook Air”

cbokode.AddItem “Apple MC969 MacBook Air”

cbokode.AddItem “Apple MC700 MacBook Pro”

cbokode.AddItem “Apple MC721 MacBook Pro”

cbokode.AddItem “Apple MC723 MacBook Pro”

cbokode.AddItem “Apple MC724 MacBook Pro”

cbokode.AddItem “Apple MC711 MacBook Pro”

cbokode.AddItem “Apple MC313 MacBook Pro”

cbokode.AddItem “Apple MC314 MacBook Pro”

cbokode.AddItem “Apple MC318 MacBook Pro”

cbokode.AddItem “Apple MC322 MacBook Pro”

cbokode.AddItem “Apple MC965 MacBook Air”

cbokode.AddItem “Apple MC966 MacBook Air”

End Sub

 

 

 

 

TUGAS 4

DATA PENJUALAN KOMPUTER

 

entri penjualan 4

 

Private Sub cbokode_Click()

Dim kk, jk, hs As String

Select Case cbokode.Text

Case “P205”

Txtjk.Text = “Pentium II 500 Mega Hz”

Txths.Text = “1500000”

Case “P308”

Txtjk.Text = “Pentium III 800 Mega Hz”

Txths.Text = “2100000”

Case “P310”

Txtjk.Text = “Pentium III 1.0 Giga Hz”

Txths.Text = “3500000”

Case “P415”

Txtjk.Text = “Pentium IV 1.5 Giga Hz”

Txths.Text = “4000000”

Case “P417”

Txtjk.Text = “Pentium IV 1.7 Giga Hz”

Txths.Text = “4200000”

Case “P419”

Txtjk.Text = “Pentium IV 1.9 Mega Hz”

Txths.Text = “5500000”

End Select

End Sub

 

Private Sub Cmdclose_Click()

End

End Sub

 

Private Sub Cmdhitung_Click()

cbokode.SetFocus

cbokode.Text = “”

Txtjk.Text = “”

Txths.Text = “”

Txtjumlah.Text = “”

Txthp.Text = “”

Txtdis.Text = “”

Txtharga.Text = “”

End Sub

 

Private Sub Cmdproses_Click()

Txthp.Text = Val(Txtjumlah.Text) * Val(Txths.Text)

If Txthp.Text > 30000000 Then

Txtdis.Text = Val(Txthp.Text) * 0.15

ElseIf Txthp.Text > 25000000 Then

Txtdis.Text = Val(Txthp.Text) * 0.1

ElseIf Txthp.Text > 20000000 Then

Txtdis.Text = Val(Txthp.Text) * 0.5

ElseIf Txthp.Text > 15000000 Then

Txtdis.Text = Val(Txthp.Text) * 0.2

End If

Txtharga.Text = Val(Txthp.Text) – Val(Txtdis.Text)

End Sub

 

Private Sub Form_Load()

cbokode.AddItem “P205”

cbokode.AddItem “P308”

cbokode.AddItem “P310”

cbokode.AddItem “P415”

cbokode.AddItem “P417”

cbokode.AddItem “P419”

End Sub

 

 

TUGAS 5

DATA BUKU STMIK PRINGSEWU

 

data buku stmik psw T5

 

Private Sub Cmdbatal_Click()

Cbokode.SetFocus

txtkode = “”

Txtjb = “”

Txtpengarang = “”

Txttt = “”

Txtpenerbit = “”

Txtharga = “”

End Sub

 

Private Sub Cmdkeluar_Click()

End

End Sub

 

Private Sub Cmdlagi_Click()

Cbokode.SetFocus

txtkode = “”

Txtjb = “”

Txtpengarang = “”

Txttt = “”

Txtpenerbit = “”

Txtharga = “”

End Sub

 

Private Sub Cmdproses_Click()

Dim KB As String

Txttt.Text = “20” & Right(Cbokode.Text, 2)

S = Mid(Cbokode.Text, 3, 3)

If S = “SIM” Then

Txtjb = “Sistem Informasi Manajemen”

Txtpengarang = “YatiNurOktavia”

Txtharga = 75900

ElseIf S = “EDP” Then

Txtjb = “Elektronik Data Processing”

Txtpengarang = “Imam Tarmizi”

Txtharga = 62000

ElseIf S = “MNJ” Then

Txtjb = “Manajemen”

Txtpengarang = “Valentina Mariana Adiwianti”

Txtharga = 42000

ElseIf S = “CDR” Then

Txtjb = “Corel Draw”

Txtpengarang = “RiyanSuhandi”

Txtharga = 53000

ElseIf S = “RPL” Then

Txtjb = “Rekayasa Perangkat Lunak”

Txtpengarang = “SintaUmpuSinga”

Txtharga = 83000

End If

S = Left(Cbokode.Text, 1)

If S = “A” Then

Txtpenerbit = “Andi Offset Yogyakarta”

ElseIf S = “I” Then

Txtpenerbit = “Indah Surabaya”

ElseIf S = “S” Then

Txtpenerbit = “Salemba Empat”

ElseIf S = “E” Then

Txtpenerbit = “Elek Media Komputindo”

ElseIf S = “M” Then

Txtpenerbit = “Maxicom”

End If

Txttt.Text = “20” & Right(Cbokode.Text, 2)

End Sub

 

Private Sub Form_Load()

Cbokode.AddItem “A-SIM-01”

Cbokode.AddItem “I-EDP-02”

Cbokode.AddItem “S-MNJ-03”

Cbokode.AddItem “E-CDR-04”

Cbokode.AddItem “M-RPL-05”

End Sub

 

 

 

 

 

TUGAS 6

PENJUALAN TIKET KERETA

 

penjualan tiket kereta T6

 

Private Sub Cmdkeluar_Click()

End

End Sub

 

Private Sub Cmdlagi_Click()

txtkt.SetFocus

txtkt.Text = “”

Txtht.Text = “”

Txtjk.Text = “”

Txtjb.Text = “”

Txtjt.Text = “”

Txttp.Text = “”

End Sub

 

Private Sub Cmdproses_Click()

Dim kt, jk, jb As String

Dim ht As Currency

kt = Left(txtkt.Text, 3)

If kt = “BIM” Then

ht = “50000”

jk = “BIMA”

jb = “1600”

ElseIf kt = “EKO” Then

ht = “35000”

jk = “EKONOMI”

jb = “1900”

ElseIf kt = “MUT” Then

ht = “23000”

jk = “MUTIARA”

jb = “1700”

ElseIf kt = “SEN” Then

ht = “15000”

jk = “SENJA”

jb = “2000”

End If

Txtht.Text = ht

Txtjk.Text = jk

Txtjb.Text = jb

Txtjt.SetFocus

End Sub

 

Private Sub Txtjt_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Txttp.Text = Val(Txtht.Text) * Val(Txtjt.Text)

Txttp.SetFocus

End If

End Sub

 

 

 

 

TUGAS 7

DATA BUKU STMIK PRINGSEWU

data buku stmik psw 2 T7

 

Private Sub Cmdbatal_Click()

Cbokode.SetFocus

Cbokode = “”

Txtjudul = “”

Txtpengarang = “”

Txttahun = “”

Txtpenerbit = “”

Txtharga = “”

End Sub

 

Private Sub Cmdkeluar_Click()

End

End Sub

 

Private Sub Cmdlagi_Click()

Cbokode.SetFocus

Cbokode = “”

Txtjudul = “”

Txtpengarang = “”

Txttahun = “”

Txtpenerbit = “”

Txtharga = “”

End Sub

 

Private Sub Cmdproses_Click()

Dim KB As String

Txttahun.Text = “20” & Right(Cbokode.Text, 2)

s = Mid(Cbokode.Text, 3, 3)

If s = “SIM” Then

Txtjb = “Sistem Informasi Manajemen”

Txtpengarang = “YatiNurOktavia”

Txtharga = 75900

ElseIf s = “EDP” Then

Txtjb = “Elektronik Data Processing”

Txtpengarang = “Imam Tarmizi”

Txtharga = 62000

ElseIf s = “MNJ” Then

Txtjb = “Manajemen”

Txtpengarang = “Valentina Mariana Adiwianti”

Txtharga = 42000

ElseIf s = “CDR” Then

Txtjb = “Corel Draw”

Txtpengarang = “RiyanSuhandi”

Txtharga = 53000

ElseIf s = “RPL” Then

Txtjb = “Rekayasa Perangkat Lunak”

Txtpengarang = “SintaUmpuSinga”

Txtharga = 83000

End If

s = Left(Cbokode.Text, 1)

If s = “A” Then

Txtpenerbit = “Andi Offset Yogyakarta”

ElseIf s = “I” Then

Txtpenerbit = “Indah Surabaya”

ElseIf s = “S” Then

Txtpenerbit = “Salemba Empat”

ElseIf s = “E” Then

Txtpenerbit = “Elek Media Komputindo”

ElseIf s = “M” Then

Txtpenerbit = “Maxicom”

End If

Txttahun.Text = “20” & Right(Cbokode.Text, 2)

End Sub

 

Private Sub Form_Load()

Cbokode.AddItem “A-SIM-01”

Cbokode.AddItem “I-EDP-02”

Cbokode.AddItem “S-MNJ-03”

Cbokode.AddItem “E-CDR-04”

Cbokode.AddItem “M-RPL-05”

End Sub

 

 

 

 

TUGAS 8

PT. PULANG PETANG SETIAP HARI

 

pt pulang petang setiap hari T8

 

 

Private Sub Cmdbatal_Click()

Txtnama.SetFocus

Txtnama.Text = “”

Txtnik.Text = “”

Txtgol.Text = “”

Txtkode.Text = “”

Txtstatus.Text = “”

Txttahun.Text = “”

Txtjabatan.Text = “”

Txtbagian.Text = “”

Txtgaji.Text = “”

Txttunjangan.Text = “”

Txttotal.Text = “”

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdlagi_Click()

Txtnama.SetFocus

Txtnama.Text = “”

Txtnik.Text = “”

Txtgol.Text = “”

Txtkode.Text = “”

Txtstatus.Text = “”

Txttahun.Text = “”

Txtjabatan.Text = “”

Txtbagian.Text = “”

Txtgaji.Text = “”

Txttunjangan.Text = “”

Txttotal.Text = “”

End Sub

 

Private Sub Cmdproses_Click()

Dim s As String

s = Mid(Txtnik.Text, 5, 1)

If s = “A” Then

Txtgol.Text = “A”

Txtjabatan.Text = “Manager”

Txtgaji.Text = “4000000”

Txttunjangan.Text = “1025000”

ElseIf s = “B” Then

Txtgol.Text = “B”

Txtjabatan.Text = “Ka.Seksi”

Txtgaji.Text = “3500000”

Txttunjangan.Text = “975000”

ElseIf s = “C” Then

Txtgol.Text = “C”

Txtjabatan.Text = “Staf”

Txtgaji.Text = “3000000”

Txttunjangan.Text = “925000”

End If

s = Mid(Txtnik.Text, 7, 1)

If s = “S” Then

Txtstatus.Text = “singel”

ElseIf s = “M” Then

Txtstatus.Text = “Menikah”

ElseIf s = “J” Then

Txtstatus.Text = “Janda”

ElseIf s = “D” Then

Txtstatus.Text = “Duda”

End If

s = Right(Txtnik.Text, 3)

If s = “KEU” Then

Txtbagian.Text = “Accounting”

ElseIf s = “ADM” Then

Txtbagian.Text = “Administrasi”

ElseIf s = “SDM” Then

Txtbagian.Text = “General Affair”

ElseIf s = “EDP” Then

Txtbagian.Text = “IT Unit”

ElseIf s = “SPM” Then

Txtbagian.Text = “Security”

End If

Txttahun.Text = Left(Txtnik.Text, 4)

Txttotal.Text = Val(Txtgaji) + Val(Txttunjangan)

End Sub

 

Private Sub Txtnama_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Txtnik.SetFocus

End If

End Sub

 

TUGAS VISUAL BASIC FONT COLOR

TUGAS 1

tugas 1

 

Private Sub CMDEXIT_Click()

End

End Sub

 

Private Sub optblue_Click()

‘Membuatteksberwarnabiru’

Lblteks.ForeColor = vbBlue

End Sub

 

Private Sub optbold_Click()

‘membuattekstebal’

If chkbold.Value = 1 Then

Lblteks.FontBold = True

Else

Lblteks.FontBold = False

End If

End Sub

 

Private Sub optgreen_Click()

‘Membuatteksberwarnahijau’

Lblteks.ForeColor = vbGreen

End Sub

 

Private Sub optitalic_Click()

‘membuatteks miring’

If chkitalic.Value = 1 Then

Lblteks.FontItalic = True

Else

Lblteks.FontItalic = False

End If

End Sub

 

Private Sub optred_Click()

‘membuatteksberwarnamerah’

Lblteks.ForeColor = vbRed

End Sub

 

Private Sub optstrikeout_Click()

‘membuatteksgaristengah’

If chkstrikethru.Value = 1 Then

Lblteks.FontStrikethru = True

Else

Lblteks.FontStrikethru = False

End If

End Sub

 

Private Sub optunderline_Click()

‘membuatteksgarisbawah’

If chkunderline.Value = 1 Then

Lblteks.FontUnderline = True

Else

Lblteks.FontUnderline = False

End If

End Sub

 

Private Sub optyellow_Click()

‘Membuatteksberwarnakuning’

Lblteks.ForeColor = vbYellow

 

End Sub

 

 

 

 

TUGAS 2

tugas2

 

Private Sub Chkmiring_Click()

Label2.FontItalic = Chkmiring.Value

End Sub

 

Private Sub Chktebal_Click()

Label2.FontBold = Chktebal.Value

End Sub

 

Private Sub Cmdok_Click()

Label2.Caption = txtnama.Text

End Sub

 

Private Sub Cmdselesai_Click()

End

End Sub

 

Private Sub Optbiru_Click()

Label2.ForeColor = vbBlue

End Sub

 

Private Sub Optmerah_Click()

Label2.ForeColor = vbRed

End Sub

 

 

TUGAH 3

TUGAS3

 

Private Sub Cbonpm_Click()

Dim nama, jurusan, mutu As String

 

Select Case cbonpm.Text

 

Case “15100008”

nama = ” AHMAD YUDI ”

jurusan = “Sistem Informasi”

Case “15100009”

nama = ” OPI LARASWATI ”

jurusan = “Sistem Informasi”

Case “15100010”

nama = ” LAILI RIZKIA PUTRI ”

jurusan = “Sistem Informasi”

 

 

End Select

txtnama.Text = nama

txtjurusan.Text = jurusan

Txtquis.SetFocus

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

Private Sub Cmdbatal_Click()

cbonpm.SetFocus

cbonpm = “”

txtnama = “”

txtjurusan = “”

Txtquis = “”

Txttugas = “”

Txtuts = “”

Txtuas = “”

Txtnilai = “”

Txtmutu = “”

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdproses_Click()

Dim nilai As Integer

Dim mutu As String

QUIS = Val(Txtquis.Text)

TUGAS = Val(Txttugas.Text)

UTS = Val(Txtuts.Text)

UAS = Val(Txtuas.Text)

nilai = (QUIS + TUGAS + UTS + UAS) / 4

Txtnilai.Text = nilai

 

Select Case Txtnilai.Text

Case Is > 80

mutu = “A”

Case Is > 70

mutu = “B”

Case Is > 60

mutu = “C”

Case Is > 50

mutu = “D”

Case Is < 50

mutu = “E”

End Select

Txtmutu.Text = mutu

End Sub

Private Sub Form_Load()

cbonpm.AddItem “15100008”

cbonpm.AddItem “15100009”

cbonpm.AddItem “15100010”

end sub

 

TUGAS 4

TUGAS 4

 

Private Sub Cbonpm_Click()

Dim nama, jurusan, mutu As String

 

Select Case cbonpm.Text

Case “15100008”

nama = ” AHMAD YUDI ”

jurusan = “Sistem Informasi”

Case “15100009”

nama = ” OPI LARASWATI ”

jurusan = “Sistem Informasi”

Case “15100010”

nama = ” LAILI RIZKIA PUTRI ”

 

End Select

txtnama.Text = nama

txtjurusan.Text = jurusan

Txtquis.SetFocus

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

Private Sub txtuas_keypress(keyAscii As Integer)

If keyAscii = 13 Then

 

Dim nilai As Integer

Dim mutu As String

QUIS = Val(Txtquis.Text)

TUGAS = Val(Txttugas.Text)

UTS = Val(Txtuts.Text)

UAS = Val(Txtuas.Text)

nilai = (QUIS + TUGAS + UTS + UAS) / 4

Txtnilai.Text = nilai

 

Select Case Txtnilai.Text

Case Is > 80

mutu = “A”

Case Is > 70

mutu = “B”

Case Is > 60

mutu = “C”

Case Is > 50

mutu = “D”

Case Is < 50

mutu = “E”

End Select

Txtmutu.Text = mutu

End If

 

End Sub

Private Sub Cmdbatal_Click()

cbonpm.SetFocus

cbonpm = “”

txtnama = “”

txtjurusan = “”

Txtquis = “”

Txttugas = “”

Txtuts = “”

Txtuas = “”

Txtnilai = “”

Txtmutu = “”

End Sub

 

Private Sub Cmdkeluar_Click()

Unload Me

End Sub

 

Private Sub Cmdproses_Click()

Dim nilai As Integer

Dim mutu As String

QUIS = Val(Txtquis.Text)

TUGAS = Val(Txttugas.Text)

UTS = Val(Txtuts.Text)

UAS = Val(Txtuas.Text)

nilai = (QUIS + TUGAS + UTS + UAS) / 4

Txtnilai.Text = nilai

 

Select Case Txtnilai.Text

Case Is > 80

mutu = “A”

Case Is > 70

mutu = “B”

Case Is > 60

mutu = “C”

Case Is > 50

mutu = “D”

Case Is < 50

mutu = “E”

End Select

Txtmutu.Text = mutu

End Sub

Private Sub Form_Load()

cbonpm.AddItem “15100008”

cbonpm.AddItem “15100009”

cbonpm.AddItem “15100010”

 

End Sub

 

TUGAS PEMROGRAMAN

TUGAS 1

 

tugas1

Private Sub Command1_Click()

Texthasil = Val(Text1) * Val(Text2)

End Sub

Private Sub Command2_Click()

Text1.SetFocus

Text1 = ” ”

Text2 = ” ”

Texthasil = ” ”

 

End Sub

 

Private Sub Command3_Click()

End

End Sub

 

Private Sub Text1_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Text2.SetFocus

End If

End Sub

 

TUGAS 2

LARAS2

Private Sub Command1_Click()

Texthasil = Val(Text1) * Val(Text2)

End Sub

Private Sub Command2_Click()

Text1.SetFocus

Text1 = ” ”

Text2 = ” ”

Texthasil = ” ”

 

End Sub

 

Private Sub Command3_Click()

End

End Sub

 

Private Sub Text1_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

Texthasil = Val(Text1) * Val(Text2)

Text2.SetFocus

End If

End Sub

 

TUGAS 3

 

laras3

 

Private Sub cmdbatal_Click()

OPI1.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

OPI4 = ” ”

OPI5 = ” ”

opi6 = ” ”

OPI7 = ” ”

OPI8 = ” ”

opi9 = ” ”

OPI10 = ” ”

OPI11 = ” ”

OPI12 = ” ”

End Sub

 

Private Sub cmdkeluar_Click()

End

End Sub

 

Private Sub cmdlagi_Click()

OPI1.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

OPI4 = ” ”

OPI5 = ” ”

op16 = ” ”

OPI7 = ” ”

OPI8 = ” ”

opi9 = ” ”

OPI10 = ” ”

OPI11 = ” ”

OPI12 = ” ”

End Sub

 

Private Sub cmdproses_Click()

OPI3 = Val(OPI1) + Val(OPI2)

opi6 = Val(OPI4) * Val(OPI5)

opi9 = Val(OPI7) – Val(OPI8)

OPI12 = Val(OPI10) / Val(OPI11)

 

End Sub

 

Private Sub OPI1_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI2.SetFocus

End If

End Sub

 

Private Sub OPI10_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI11.SetFocus

End If

End Sub

 

 

Private Sub OPI11_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI12 = Val(OPI10) / Val(OPI11)

End If

End Sub

 

Private Sub OPI2_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI3 = Val(OPI1) + Val(OPI2)

OPI4.SetFocus

End If

End Sub

 

Private Sub OPI4_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI5.SetFocus

End If

End Sub

 

Private Sub OPI5_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

opi6 = Val(OPI4) * (OPI5)

OPI7.SetFocus

End If

End Sub

 

Private Sub OPI7_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI8.SetFocus

End If

End Sub

 

Private Sub OPI8_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

opi9 = Val(OPI7) – Val(OPI8)

OPI10.SetFocus

End If

End Sub

 

TUGAS 4

 

TUGAS4

 

Private Sub cmdbatal_Click()
OPI1.SetFocus
OPI1 = ” ”
OPI2 = ” ”
OPI3 = ” ”
OPI4 = ” ”
OPI5 = ” ”
opi6 = ” ”
OPI7 = ” ”
OPI8 = ” ”
opi9 = ” ”
OPI10 = ” ”
OPI11 = ” ”
OPI12 = ” ”
End Sub

Private Sub cmdkeluar_Click()
End
End Sub

Private Sub cmdlagi_Click()
OPI1.SetFocus
OPI1 = ” ”
OPI2 = ” ”
OPI3 = ” ”
OPI4 = ” ”
OPI5 = ” ”
op16 = ” ”
OPI7 = ” ”
OPI8 = ” ”
opi9 = ” ”
OPI10 = ” ”
OPI11 = ” ”
OPI12 = ” ”
End Sub

Private Sub cmdproses_Click()
OPI3 = Val(OPI1) + Val(OPI2)
opi6 = Val(OPI4) * Val(OPI5)
opi9 = Val(OPI7) – Val(OPI8)
OPI12 = Val(OPI10) / Val(OPI11)

End Sub

Private Sub OPI1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI2.SetFocus
End If
End Sub

Private Sub OPI10_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI11.SetFocus
End If
End Sub

Private Sub OPI11_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
End If
End Sub

Private Sub OPI2_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI4.SetFocus
End If
End Sub

Private Sub OPI4_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI5.SetFocus
End If
End Sub

Private Sub OPI5_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI7.SetFocus
End If
End Sub

Private Sub OPI7_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI8.SetFocus
End If
End Sub

Private Sub OPI8_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI10.SetFocus
End If
End Sub

 

TUGAS 5

laras5

Private Sub cmdhitung_Click()

OPI2 = Val(OPI1) * (0.1)

OPI3 = Val(OPI1) – Val(OPI2)

End Sub

 

Private Sub cmdquit_Click()

End

End Sub

 

Private Sub cmdulangi_Click()

OPI3.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

End Sub

 

TUGAS 6

laras5

Private Sub cmdhitung_Click()

OPI2 = Val(OPI1) * (0.1)

OPI3 = Val(OPI1) – Val(OPI2)

End Sub

 

Private Sub cmdquit_Click()

End

End Sub

 

Private Sub cmdulangi_Click()

OPI3.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

End Sub

 

Private Sub OPI1_KeyPress(KeyAscii As Integer)

OPI2 = Val(OPI1) * (0.1)

OPI3 = Val(OPI1) – Val(OPI2)

End Sub

 

Private Sub OPI2_KeyPress(KeyAscii As Integer)

OPI3.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

End Sub

 

TUGAS 7

7

Private Sub CMDKELUAR_Click()

End

End Sub

 

Private Sub CMDPROSES_Click()

OPI4 = Val(OPI1) + Val(OPI2) – Val(OPI3)

OPI5 = Val(OPI4) * 0.1

OPI6 = Val(OPI4) – Val(OPI5)

End Sub

 

Private Sub CMDULANG_Click()

OPI1.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

OPI4 = ” ”

OPI5 = ” ”

OPI6 = ” ”

End Sub

 

Private Sub OPI1_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI2.SetFocus

End If

End Sub

 

Private Sub OPI2_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI3.SetFocus

End If

End Sub

 

Private Sub OPI3_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI4 = Val(OPI1) + Val(OPI2) – Val(OPI3)

OPI5 = Val(OPI4) * 0.1

OPI6 = Val(OPI6) – Val(OPI5)

End If

End Sub

 

Tugas8

 

Private Sub CMDKELUAR_Click()

End

End Sub

 

Private Sub CMDPROSES_Click()

OPI4 = Val(OPI1) + Val(OPI2) – Val(OPI3)

OPI5 = Val(OPI4) * 0.1

OPI6 = Val(OPI4) – Val(OPI5)

End Sub

 

Private Sub CMDULANG_Click()

OPI1.SetFocus

OPI1 = ” ”

OPI2 = ” ”

OPI3 = ” ”

OPI4 = ” ”

OPI5 = ” ”

OPI6 = ” ”

End Sub

 

Private Sub OPI1_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI2.SetFocus

End If

End Sub

 

Private Sub OPI2_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI3.SetFocus

End If

End Sub

 

Private Sub OPI3_KeyPress(KeyAscii As Integer)

If KeyAscii = 13 Then

OPI4 = Val(OPI1) + Val(OPI2) – Val(OPI3)

OPI5 = Val(OPI4) * 0.1

OPI6 = Val(OPI4) – Val(OPI5)

End If

End Sub

 

TUGAS 8

7

 

Private Sub CMDKELUAR_Click()
End
End Sub

Private Sub CMDPROSES_Click()
OPI4 = Val(OPI1) + Val(OPI2) – Val(OPI3)
OPI5 = Val(OPI4) * 0.1
OPI6 = Val(OPI4) – Val(OPI5)
End Sub

Private Sub CMDULANG_Click()
OPI1.SetFocus
OPI1 = ” ”
OPI2 = ” ”
OPI3 = ” ”
OPI4 = ” ”
OPI5 = ” ”
OPI6 = ” ”
End Sub

Private Sub OPI1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI2.SetFocus
End If
End Sub

Private Sub OPI2_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI3.SetFocus
End If
End Sub

Private Sub OPI3_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
OPI4 = Val(OPI1) + Val(OPI2) – Val(OPI3)
OPI5 = Val(OPI4) * 0.1
OPI6 = Val(OPI6) – Val(OPI5)
End If
End Sub

Tugas 2 Visual Basic Pemrograman 1

 

Private Sub Command1lagi_Click()
opinpm.SetFocus
opinpm = ” ”
opinama = ” ”
opialamat = ” ”
opiprogramstudi = ” ”
opijurusan = ” ”
opiagama = ” ”
End Sub

Private Sub Command2batal_Click()
opinpm.SetFocus
opinpm = ” ”
opinama = ” ”
opialamat = ” ”
opiprogramstudi = ” ”
opijurusan = ” ”
opiagama = ” ”
End Sub

Private Sub Command3keluar_Click()
End
End Sub

Private Sub opialamat_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
opiprogramstudi.SetFocus
End If
End Sub

Private Sub opijurusan_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
opiagama.SetFocus
End If
End Sub

Private Sub opinama_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
opialamat.SetFocus
End If
End Sub

Private Sub opinpm_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
opinama.SetFocus
End If
End Sub

Private Sub opiprogramstudi_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
opijurusan.SetFocus
End If
End Sub

Tugas 1 Visual Basic Pemrograman 1

tgs1.PNG

Private Sub Command1_Click()
Text1.SetFocus
Text1 = ” ”
Text2 = ” ”
Text3 = ” ”
End Sub

Private Sub Command2_Click()
Text1.SetFocus
Text1 = ” ”
Text2 = ” ”
Text3 = ” ”
End Sub

Private Sub Command3_Click()
End
End Sub

Private Sub Form_Load()

End Sub

Private Sub Text1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
Text2.SetFocus
End If
End Sub
Private Sub Text2_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
Text3.SetFocus
End If
End Sub

Berazam Istiqamah

Meneladani Rasulullah SAW.

 

REPUBLIKA.CO.ID, Oleh: Muhammad Arifin Ilham

Teruslah berazam untuk istiqamah, di mana pun kapan pun dan dalam kondisi bagaimana pun. Mengapa perlu untuk terus istiqamah? Karena hikmahnya tidak hanya kita dapatkan kelak di akhirat, bahkan saat ini, di tempat ini, buah dari istiqamah itu terlalu nikmat dan lezat untuk kita rasakan di dunia ini.

Pertama, istiqamah adalah perintah Allah dan Rasul-Nya, “Dan beribadahlah kepada Allah sampai ajal tiba” (QS Al-Hijr [15]: 99). “Wahai Rasulullah, katakanlah kepadaku dalam Islam satu perkataan yang aku tidak akan menanyakannya kepada seorangpun selain padamu. Rasulullah menjawab, “Katakanlah, saya beriman kemudian istiqamahlah.” (HR Muslim).

Kedua, sunah utama Rasulullah SAW, “Sungguh pada diri Rasulullah ada teladan terbaik bagi kalian.” (QS Al-Ahzab [33]: 21). Rasulullah SAW bersabda, ”Wahai sekalian manusia, lakukanlah amalan sesuai dengan kemampuan kalian. Karena Allah tidaklah bosan sampai kalian merasa bosan. (Ketahuilah bahwa) amalan yang paling dicintai oleh Allah adalah amalan yang terus menerus (ajeg) meski sedikit.” (HR Muslim).

Ketiga, Allah SWT akan perbaiki keadaannya, “Dan mereka yang beriman atas apa yang Allah turunkan kepada Nabi Muhammad dan itu haq dari Allah, maka Allah maafkan kesalahan mereka dan Allah perbaiki keadaan mereka.” (QS Muhammad [47]: 2).

Keempat, pahala yang tidak terputus, “Kecuali bagi mereka yang beriman dan beramal saleh untuk mereka ganjaran yang tidak terputus,” (QS At-Tiin [95]: 6). “Jika seseorang sakit atau melakukan safar, maka dia akan dicatat melakukan amalan sebagaimana amalan rutin yang dia lakukan ketika mukim (tidak bepergian) dan dalam keadaan sehat.” (HR Bukhari).

Kelima, dikagumi para malaikat sebagaimana para malaikat selalu dalam istiqamah. Allah SWT berkenan menolong untuk semua urusan dunia dan akhiratnya. Bahkan dipenuhi kebutuhannya. Doanya diijabah dan insya Allah masuk surga-Nya.

Sesungguhnya orang-orang yang mengatakan, “Tuhan kami ialah Allah” kemudian mereka meneguhkan pendirian mereka, maka malaikat akan turun kepada mereka (dengan mengatakan), ‘Janganlah kamu merasa takut dan janganlah kamu merasa sedih; dan bergembiralah kamu dengan surga yang telah dijanjikan Allah kepadamu. Kamilah Pelindung-pelindungmu dalam kehidupan dunia dan di akhirat; di dalamnya kamu memperoleh apa yang kamu inginkan dan memperoleh (pula) di dalamnya apa yang kamu minta sebagai hidangan (bagimu) dari Tuhan Yang Maha Pengampun lagi Maha Penyayang’.” (QS Fashilat [41]: 30-32).

Berikutnya, selalu dalam hidayah Allah dan selalu bersama Allah, “Mereka yang sungguh-sungguh istiqamah mendekatkan diri kepada Allah maka Allah tunjukkan jalan hidayah-Nya, dan sesungguhnya Allah benar-benar bersama para hamba-Nya yang selalu berbuat baik.” (QS Al-Ankabut [29]: 69).

Meraih rahmat Allah, “Sesungguhnya rahmat Allah amat dekat kepada orang-orang yg selalu berbuat baik.” (QS Al-A’raf [7]: 56). Saat susah akan ditolong Allah. “Kenalilah Allah di waktu lapang, niscaya Allah akan mengenalimu ketika susah” (HR Al Hakim).

Sungguh, istiqmah itu adalah amalan hamba Allah yang sangat paham dunia ini sebentar sehingga disibukkan dengan beramal ibadah sesuai dengan visi-misi hidup Islami, dan tidak ada lagi perbuatan sia-sia, mubazir apalagi maksiat, “Orang orang beriman itu meninggalkan perkataan perbuatan yang tidak berguna.” (QS Al-Mu’minun [23]: 3).

Rasulullah bersabda, “Di antara tanda kebaikan Islam seseorang adalah meninggalkan perkara-perkara yang tidak bermanfaat baginya.” (HR At-Tirmidzî). Semoga terus bergelora semangat berazam dalam istiqamah.

 

Sumber

http://www.republika.co.id/berita/dunia-islam/hikmah/15/10/23/nwngvz301-berazam-istiqamah

Kisah Persahabatan Seorang Muslim dan Nasrani di Damaskus

Imam Masjid Al Hikmah New York, Imam Shamsi Ali.

 

REPUBLIKA.CO.ID, NEW YORK — Imam Masjid Al Hikmah New York, Imam Shamsi Ali berbagi kisah menarik terkait persahabatan seorang Muslim dan Nasrani. Kebetulan, keduanya saling memiliki kekurangan masing-masing. Berikut kisah persahabatan kedua orang Suriah itu yang diunggah melalui akun Facebook miliknya:

Kisah persahabatan!

Yang jangkung kurus dan buta bernama Muhammad seorang Muslim. Dan yang pendek lumpuh itu bernama Samir seorang Nasrani .

Foto ini di ambil di Damaskus, pada tahun 1889.

Keduanya sejak kecil telah menjadi yatim piatu. Muhammad menggunakan mata Samir untuk melihat dan Samir menggunakan kaki Muhammad untuk berjalan. Keduanya bekerja di sebuah kedai kopi , tentu keduanya saling menopang dalam kehidupan.

Mereka berdua di karuniai umur yang sangat panjang, sejak kecil hingga tua mereka hidup serumah dengan menopang satu sama lain. Mereka sahabat sehidup semati.

Samir meninggal terlebih dahulu , dan seminggu kemudian Muhammad juga meninggal karena kesedihan yang mendalam . Keduanya memiliki keyakinan berbeda tetapi jiwa mereka sama.

Kisah sepasang sahabat ini tidak perlu di kisahkan panjang lebar, karena kita sudah bisa mengambil hikmah sangat berharga dari keduanya.

Keyakinan bukan sebuah kesalahan untuk saling mengerti, memahami, menyayangi, mengasihi, dan saling menghormati satu sama lain.

Sumber

http://khazanah.republika.co.id/berita/dunia-islam/islam-nusantara/15/11/03/nx7vuy334-kisah-persahabatan-seorang-muslim-dan-nasrani-di-damaskus

Cerita Hikmah, Mendidik Anak untuk Mandiri Meski Tak Bisa Melihat

Cerita Hikmah, Mendidik Anak untuk Mandiri Meski Tak Bisa Melihat

 

Jakarta, Hikmah mengaku tak pernah siap melahirkan anak dengan gangguan penglihatan. Walau begitu, ia bertekad membekali sang anak yang tunanetra agar kelak bisa mandiri.

Anak laki-lakinya, Hilmi (17) terlahir dengan glaukoma yang memberinya gangguan low vision. Umur 5 tahun, dinyatakan oleh dokter bahwa kondisi sang buah hati tidak mungkin disembuhkan. Hikmah harus menerima kenyataan, anaknya menjadi tunanetra.

“Saya akui banyak kesalahan dalam mendidik Hilmi. Dulu, biar dia mau belajar Braille sampai saya teteskan lilin di jarinya,” kenang Hikmah di sela-sela outing class untuk tunanetra di Lapangan Randu, Kebun Raya Bogor, Sabtu (17/10/2015).

Hingga akhirnya, Hikmah disarankan oleh dokter mata untuk merasakan sendiri pengalaman menjadi tunanetra. Ia diminta menutup mata, yang oleh Direktur Eksekutif Yayasan Mitra Netra H Bambang Basuki disebut sebagai proses sensitinzing.

Sejak saat itu Hikmah membuka diri untuk belajar. Dari para dokter maupun komunitas orang tua dengan anak tunanetra, ia mendapat banyak pengetahuan berharga tentang cara-cara yang benar untuk mendidik anak berkebutuhan khusus seperti Hilmi.

“Di angkot, selalu ada yang merhatiin lalu tanya ‘anaknya nggak lihat ya?’ dan selalu saya arahkan Hilmi untuk menjawab sendiri pertanyaan semacam itu. Tiap kali pindah rumah, yang pertama kali saya lakukan ke tetangga adalah memperkenalkan bahwa anak saya tunanetra,” kata Hikmah.

Banyak keuntungan yang dirasakan Hikmah dengan keputusannya untuk membuka diri seperti itu. Dengan mengetahui kondisi Hilmi, lingkungan di sekitar mereka akan cenderung lebih bisa menerima dan tidak mencemoohnya.

Banyak anak berkebutuhan khusus tidak seberuntung Hilmi. Dituturkan oleh Hikmah, di lingkungan tempat tinggalnya sendiri juga ada anak dengan Down Syndrome yang ‘diumpetin’ oleh orang tuanya. Banyak alasan orang tua memperlakukan anaknya demikian, mulai dari malu hingga benar-benar tidak tahu harus disekolahkan di mana.

Saat ini, Hilmi belajar di sebuah Sekolah Luar Biasa (SLB). Pernah suatu ketika Hilmi masuk pesantren, namun hanya bertahan 3 bulan. Sang ibu, Hikmah tidak mau menyalahkan siapapun. Baginya, itu berarti Hilmi belum cukup siap untuk mandiri di tempat tersebut.

Walau anaknya harus belajar di SLB, Hikmah tidak merasa kecewa. Baginya jauh lebih membahagiakan melihat sang anak dengan segala kondisinya tetap mengejar cita-citanya sebagai penghafal Al Quran di tempat lain daripada memaksakan sang anak belajar di sekolah umum.

“Satu kata yang saya nggak suka adalah ‘kasihan’. Karena kasihan itu juga akhirnya banyak yang jadi peminta-minta,” pungkasnya.

 

Sumber

http://health.detik.com/read/2015/10/17/153831/3046411/763/cerita-hikmah-mendidik-anak-untuk-mandiri-meski-tak-bisa-melihat

Hikmah Berpuasa Pada 10 Muharram

Hikmah Berpuasa Pada 10 Muharram

INILAHCOM, Jakarta — Seseorang bertanya kepada Ustadz Ammi Nur Baits. Dia mendengar bahwa setiap 10 Muharram orang Islam disunnahkan untuk berpuasa. Apa saja hikmah puasa 10 Muharram tersebut?

Rasulullah saw menganjurkan agar berpuasa di hari-hari diluar bulan Ramadhan, diantaranya adalah hari asy Syura, sebagaimana diriwayatkan dari Muawiyah bin Abu Sofyan berkata,”Aku mendengar Rasulullah saw bersabda,Sesungguhnya ini adalah hari asy Syura dan tidaklah diwajibkan terhadap kalian untuk berpuasa (di hari ini). Dan aku saat ini berpuasa maka barangsiapa yang ingin berpuasa (maka berpuasalah) dan barangsiapa yang ingin berbuka (tidak berpuasa) maka berbukalah.”(Muttafaq Alaihi).

Berpuasanya Rasulullah saw pada hari asy Syura adalah disebabkan bahwa Musa as telah berpuasa pada hari itu. Dan hari itu adalah hari diselamatkannya Musa dari Firaun. Diriwayatkan dari Ibnu Abbas berkata,”Ketika Nabi saw memasuki kota Madinah beliau saw menyaksikan orang-orang Yahudi berpuasa pada hari asy Syura.

Beliau berkata,”Ada apa ini?” mereka menjawab,”Hari baik, di hari ini Allah telah menyelamatkan Musa dan Bani Israil dari musuh-musuh mereka dan Musa berpuasa (di hari ini).” Lalu Nabi saw bersabda,”Aku lebih berhak terhadap Musa daripada kalian.” Maka beliau saw pun berpuasa dan memerintahkan untuk berpuasa.” (Muttafaq Alaihi).

Dari Abu Musa al Asyariy berkata,”Hari asy Syura diagungkan oleh orang-orang Yahudi dan mereka pun menjadikannya sebagai hari raya. Dan Rasulullah saw bersabda,Berpuasalah kalian (di hari ini).” (Muttafaq Alahi). (Markaz al Fatwa no. 32561). [ ]

– See more at: http://mozaik.inilah.com/read/detail/2244557/hikmah-berpuasa-pada-10-muharram#sthash.dhFq1R1R.dpuf

Sumber