4.1 PT PULANG PETANG
Private sub txtnama_keypress(key ASCII As integer)
if keyASCII =13 then
txtNIK.setfocus
end if
end sub
private sub cmdproses_clik()
dim jbt, BG, as string
dim GP, TJ, TG As curency
txt tahun. text = left (txtnik.text,4)
G= Mid (txtnik.text ,5,1)
if G= “A” then
G = “A”
JBT=”Manajer”
GP=” 4000000″
TJ= “1025000”
Else if G=”B” Then
G=”B”
JBT=”Kep.seksi”
GP=” 3500000″
TJ=”975000″
Else if G=”C” Then
G=”C”
JBT=”Sataf”
GP=” 3000000″
TJ=”925000″
end if
txtGol.text=G
txtJabatan.text= JBT
txtGapok.text= GP
txtTunjangan.text= TJ
KS= Mid (txtnik. text,7,1)
if = ks=”s” then
ks=”s”
ks status= “single’
else if ks=”M” then
ks=”M”
Ks status=”Menikah”
else if ks=”J” then
ks=”J”
Ks status=”janda”
else if ks=”D” then
ks=”D”
Ks status=”duda”
End if
txtkode. text= ks
txtstatus.text= ks status
TG=val(txt Gapok.text)+val(txttunjangan.text) txt total G.text=TG
B= Right (txtnik. text, 3)
if B =”Keu” then
txt bagian.text=”acurency”
else if B=”ADM” Then
txt Bg.text=” Administrasi”
else if B=”SDM” Then
txt Bg.text=” General afair”
else if B=”EDP” Then
txt Bg.text=” IT Unit”
else if B=”SPM” Then
txt Bg.text=” Acurency”
end if
end sub
private sub cmdkeluar_click()
end
end sub
Private Sub CmdBatal_Click()
TxtNAMA.SetFocus
TxtNAMA.Text = “”
TxtNIK.Text = “”
TxtGOL.Text = “”
TxtKS.Text = “”
TxtSTS.Text = “”
TxtTH.Text = “”
TxtJBT.Text = “”
TxtBGN.Text = “”
TxtGP.Text = “”
TxtTJ.Text = “”
TxtTG.Text = “”
End Sub
Private Sub CmdzhLAGI_Click()
TxtZHNAMA.SetFocus
TxtZHNAMA.Text = “”
TxtZHNIK.Text = “”
TxtZHGOL.Text = “”
TxtZHKS.Text = “”
TxtZHSTS.Text = “”
TxtZHTH.Text = “”
TxtZHJBT.Text = “”
TxtZHBGN.Text = “”
TxtZHGP.Text = “”
TxtZHTJ.Text = “”
TxtZHTG.Text = “”
End Sub
4.2 DATA BUKU STMIK PRINGSEWU
private sub cmd proses_clik()
dim JB,PGR, PNRBIT As string
dim TT, HRG As curency
Txt kode buku.text=left(txtkode buku.text,3)
if TB=”SIM” Then
TB=” SIM”
JB=”SISTEM INFORMASI”
PGR=”FADYA ULFA”
HRG=” 75900″
Else if TB=”EDP” Then
TB=” EDP”
JB=”ELEKTRONIK DATA PROCESSING”
PGR=”NURUL AGUSTINA”
HRG=” 62000″
Else if TB=”MNJ” Then
TB=” MNJ”
JB=”MANAJEMEN”
PGR=”RIAN HIDAYAT”
HRG=” 42000″
Else if TB=”CDR” Then
TB=” CDR”
JB=”COREL DRAW”
PGR=”SITI NUR KHOTIMAH”
HRG=” 53000″
Else if TB=”RPL” Then
TB=” RPL”
JB=”REKAYASA PERANGKAT LUNAK”
PGR=”WINDA ERLIANTI”
HRG=” 83000″
End if
txt Tipe buku. Text = TB
txtJudul buku. Text = JB
txt pengarang. Text = PGR
txtharga. Text = HRG
txt tahun terbit. text =”20″ & MID (txt kode buku.text,6,2)
KB= Right (txtkode buku.text,1)
if KB= “A” Then
KB=” A”
PNRBIT=” ANDI OFFSET YOGYAKARTA”
Else if KB= “I” Then
KB=” I”
PNRBIT=” INDAH SURABAYA”
Else if KB= “S” Then
KB=” S”
PNRBIT=” SALEMBA EMPAT”
Else if KB= “E” Then
KB=” E”
PNRBIT=” ELEK MEDIA KOMPUTINDO”
Else if KB= “M” Then
KB=” M”
PNRBIT=” MAXICOM”
End if
txtkode buku.text= KB
txtpenerbit.text= PNRBIT
private sub cmdkeluar_click()
end
end sub
private sub cmdbatal_click()
txtkode buku.set focus
txtkode buku.text=” ”
txtjudul buku.text=” ”
txtpengarang.text=” ”
txttahun terbit.text=” ”
txtpenerbit.text=” ”
txtharga.text=” ”
private cmdlagi_click()
txtkode buku.set focus
txtkode buku.text=” ”
txtjudul buku.text=” ”
txtpengarang.text=” ”
txttahun terbit.text=” ”
txtpenerbit.text=” ”
txtharga.text=” ”
end sub
4.3 DATA BUKU STMIK PRINGSEWU 2
Private sub cmdproses_clik()
dim JB, PGR, PNRBIT, As string
dim TT, HRG, As curency
txtkode buku. text= left (txtkode buku.text 1)
if KB=” A” Then
KB=” A”
PNRBIT= “ANDI OFFSET YOGYAKARTA”
Else if KB=”I” Then
KB=” I”
PNRBIT= “INDAH SURABAYA”
Else if KB=”S” Then
KB=” S”
PNRBIT= “SALEMBA EMPAT”
Else if KB=”E” Then
KB=” E”
PNRBIT= “ELEK MEDIA KOPUNTINDO”
Else if KB=”M” Then
KB=” M”
PNRBIT= “MAXICOM”
End if
txtkode buku.text= KB
txtPenerbit.text= PNRBIT
kode buku= MID (Txtkode buku.text,5,3)
if TB=” SIM” Then
TB=”SIM”
JB=”SISTEM INFORMASI MANAJEMEN”
PGR=”ANDRA SETIAWAN”
HRG=”75900″
Else if TB=” EDP” Then
TB=”EDP”
JB=”ELEKTRONIK DATA PROCESSING”
PGR=”DESI ISTIQOMAH”
HRG=”62000″
Else if TB=” EMJ” Then
TB=”EMJ”
JB=”MANAJEMEN”
PGR=”SANDI FITRAJAYA”
HRG=”42000″
Else if TB=” CDR” Then
TB=”CDR”
JB=”COREL DRAW”
PGR=”TRI INDAH SARI”
HRG=”53000″
Else if TB=” RPL” Then
TB=”RPL”
JB=”REKAYASA PERANGKAT LUNAK”
PGR=”ERNITA”
HRG=”83000″
End if
txt Tipe buku. Text = TB
txtJudul buku. Text = JB
txt pengarang. Text = PGR
txtharga. Text = HRG
Txt tahun terbit.text=”20″ & Right (txt kode buku.text,2)
private sub cmdkeluar_click()
end
end sub
private sub cmdbatal_click()
txtkode buku.set focus
txtkode buku.text=” ”
txtjudul buku.text=” ”
txtpengarang.text=” ”
txttahun terbit.text=” ”
txtpenerbit.text=” ”
txtharga.text=” ”
private cmdlagi_click()
txtkode buku.set focus
txtkode buku.text=” ”
txtjudul buku.text=” ”
txtpengarang.text=” ”
txttahun terbit.text=” ”
txtpenerbit.text=” ”
txtharga.text=” ”
end sub
4.4 DATA BUKU STMK PRINGSEWU 3 (combo)
private sub CboKode buku_click()
select case Cbokode buku.text
case”A-SIM-01″
case”I-EDP-02″
case”S-MNJ-03″
case”E-CDR-04″
case”M-RPL-05″
End select
end sub
private sub cmdproses_click()
dim PNRBIT,JB, PGR As string
dim HRG As curency
penerbit = Left (cbokode buku.text,1)
if PNRBIT=” A” Then
PNRBIT=”A”
Penerbit=”ANDI OFFSET YOGYAKARTA”
Else if PNRBIT=” I” Then
PNRBIT=”I”
Penerbit=”INDAH SURABAYA”
Else if PNRBIT=” S” Then
PNRBIT=”S”
Penerbit=”SALEMBA EMPAT”
Else if PNRBIT=” E” Then
PNRBIT=”E”
Penerbit=”ELEK MEDIA KOMPUTINDO”
Else if PNRBIT=”M” Then
PNRBIT=”M”
Penerbit=”MAXICOM”
End if
txtpnrbit.text= penerbit
JB= MID (Cbokodebuku.text,5,3)
if JB=”SIM” Then
JB=”sistem informasi manajemen”
PGR=” YATI NUR OKTAVIA”
HRG=”759000″
Else if JB=”EDP” Then
JB=”ELEKTRONIK DATA PROCESSING”
PGR=” IMAM TARMIZI”
HRG=”62000″
Else if JB=”MNJ” Then
JB=”MANAJEMEN”
PGR=” VALENTINA MARIANA ADIWIANTI”
HRG=”42000″
Else if JB=”CDR” Then
JB=”COREL DRAW”
PGR=” RIYAN SUHANDI”
HRG=”53000″
Else if JB=”RPL” Then
JB=”REKAYASA PERANGKAT LUNAK”
PGR=” SINTA UMPU SINA”
HRG=”83000″
End if
txtpJB.text= judul buku
txtPGR.text= pengarang
txtHRG.text= harga
Tahun=”20″& Right (cbokode buku.text,2)
txtTT.text= tahun terbit
end sub
private sub form_load()
cbokode buku.addItem”A-SIM-01″
cbokode buku.addItem”I-EDP-02″
cbokode buku.addItem”S-MNJ-03″
cbokode buku.addItem”E-CDR-04″
cbokode buku.addItem”M-RPL-05″
End sub
private sub cmd keluar-click()
unload me
end sub
private sub cmdLagi_click()
kosong
end sub
public sub kosong()
cbokode buku.setfocus
cbokode buku .text=” ”
txtJudul buku.text=” ”
txtpengarang.text=” ”
txtpenerbit.text=” ”
txtharga.text=” ”
txttahun terbit.text=” ”
end sub