Selasa, 12 Desember 2017

Tugas 3.6


Private Sub cmdbatal_Click()
cbokode = ""
txtjudul = ""
txtpengarang = ""
txttahun = ""
txtpenerbit = ""
txtharga = ""
cbokode.SetFocus
End Sub

Private Sub cmdkeluar_Click()
End
End Sub

Private Sub cmdlagi_Click()
cbokode = ""
txtjudul = ""
txtpengarang = ""
txttahun = ""
txtpenerbit = ""
txtharga = ""
cbokode.SetFocus
End Sub

Private Sub cmdproses_Click()
Dim A As String
A = Left(txtkode, 3)
If A = "SIM" Then
txtjudul = "Sistem Informasi Manajemen"
txtpengarang = "Fadiya Ulfa"
txtharga = "75900"
ElseIf A = "EDP" Then
txtjudul = "Elektronik Data Processing"
txtpengarang = "Nurul Agustina"
txtharga = "62000"
ElseIf A = "MNJ" Then
txtjudul = "Manajemen"
txtpengarang = "Rian Hidayat"
txtharga = "42000"
ElseIf A = "CDR" Then
txtjudul = "Corel Draw"
txtpengarang = "Siti Nur Khotimah"
txtharga = "53000"
ElseIf A = "RPL" Then
txtjudul = "Rekayasa Perangkat Lunak"
txtpengarang = "Winda Erlianti"
txtharga = "83000"
End If
txttahun = "20" & Mid(txtkode, 5, 2)
A = Right(txtkode, 1)
If A = "A" Then
txtpenerbit = "Andi Offset Yogyakarta"
ElseIf A = "I" Then
txtpenerbit = "Indah Surabaya"
ElseIf A = "S" Then
txtpenerbit = "Salemba Empat"
ElseIf A = "E" Then
txtpenerbit = "Elek Media Komputindo"
ElseIf A = "M" Then
txtpenerbit = "Maxicom"
End If
End Sub

0 komentar:

Posting Komentar