Anda di halaman 1dari 11

PENGOLAHAN DATA PENGIRIMAN PAKET DI PT.

POS INDONESIA SURAKARTA


MENGGUNAKAN BAHASA PEMROGRAMAN VISUAL BASIC 6.0

Didik Warasto, ST., M.Kom


didik_warasto@yahoo.com – Manajemen Informatika – Politama Surakarta

ABSTRAKSI

"Data-Processing of Package Delivery In PT. Post of Indonesia surakarta use the programming
language visual basic 6.0. with the progress of information technology in this time computer play a part
very important in the world of job. In technological growth this computer can assist the us in producing
and to save information in a complex system information.
In general computer used for the hollowing of duty like typing, but in fact knowledge about
computer need more developing so that can overcome the problems which complex progressively.
As for one of example of problems able to be overcome with the computer peripheral that is
problems of delivery of goods package that happened in PT. Post of Indonesia Surakarta By using
programming language of visual basic 06, in this paper writer hope can assist the PT. Post of Indonesia
Surakarta in solving problems of delivery of goods package especially, so that will get the data and report
which quickly, precisely and accurate. By using input of scrip certificate transaction, town data, data of
tariff of package and transaction claim so that can complete the process which have there.

Keywords : Data-Processing, Visual Basic, system information

1. Pendahuluan. Dengan alasan tersebut perusahaan-


1.1.Latar Belakang perusahaan mulai merubah system pengolahan
Kemajuan teknologi informasi saat ini data dalam usaha tersebut yang semula
mangakibatkan bidang komputer memegang dikerjakan secara manual menjadi
peranan sangat penting dalam dunia kerja. terkomputerisasi.
Komputar merupakan alat yang sangat penting 1.3. Tujuan
dalam memecahkan berbagai masalah yang Setelah memberikan uraian program aplikasi
sedang dihadapi. dalam makalah ini, maka tujuan penulis
Bidang-bidang yang menggunakan komputer adalah :
sebagai sarana pengolahan data untuk 1. Pengiriman paket yang dilakukan dengan
membantu memecahkan pekerjaan yang sedang cara komputerisasi akan lebih efektif dan
dihadapi antara lain : pada bidang keuangan, efisien dalam segi tenaga maupun waktu
bidang kepegawaian bidang administrasi dan dibandingkan dengan cara manual .
lain-lain. Dengan menggunakan komputer 2. Program yang penulis susun dapat
berbagai masalah yang berhubungan dengan digunakan sebagai alat yang dapat
pengolahan data dapat terselesaikan dengan menghasilkan laporan yang lebih cepat,
mudah dan waktu yang dibutuhkan juga lebih akurat dan tepat.
cepat. Dengan membandingkan komputer 1.4. Manfaat
dengan tenaga manusia dalam memproses dan Penelitian ini dibuat dengan maksud untuk
mengolah data, maka akan lebih baik dan lebih bisa bermanfaat dengan penerapan system
tepat jika menggunakan komputer. komputerisasi yang terpadu dalam pengiriman
1.2. Rumusan Masalah paket maka diperlukan juga biaya yang lebih
Masalah-masalah yang dihadapi pada dibandingkan dengan cara manual.
perusahaan begitu banyak. Untuk mengatasi
masalah tersebut komputer merupakan solusi 2. Tinjauan Pustaka
yang tepat untuk menanganinya. Supaya data Program adalah kegiatan-kegiatan prinsip yang
dapat diproses dalam waktu yang cepat, tepat telah ditentukan untuk dilaksanakan oleh
dan lebih akurat, sehingga akan didapatkan organisasi dengan maksud untuk menerapkan
hasil yang lebih jelas. strategi-strategi yang telah disusun. (Dr.
Jogiyanto H.M., M. B. A. Akt). Dalam bukunya .Row = 0
.Col = 0: .Text = " NO"
Sistem Informasi Berbasis Komputer Edisi 2. .Col = 1: .Text = "KODE POS"
3. Metode Penelitian .Col = 2: .Text = "NAMA KOTA"
Manajemen pengelolaan database (basis data) .Col = 3: .Text = "PROPINSI"
End With
yang memungkinkan kita dapat merancang End Sub
sendiri format penyimpanan informasi, Private Sub IsiGrid()
Set RS = New ADODB.Recordset
menyimpan data dalam jumlah besar, menata RS.Open "KOTA", Cn, adOpenStatic, adLockReadOnly
data dalam bentuk tabel, mengolah data With Grid
menjadi informasi dan menyajikan dalam Counter = 1
.Row = 0
bentuk laporan. Microsoft Visual Basic 6.0 While Not RS.EOF
Maka peneliti menggunakan metode penelitian .AddItem Counter
aplikasi berbasis desktop yang dipilih karena .Row = .Rows - 1
.Col = 1: .Text = "" & RS(0)
merupakan bahasa pemrograman tingkat tinggi .Col = 2: .Text = "" & RS(1)
yang berorientasi pada obyek dan juga .Col = 3: .Text = IIf(RS(2) <> vbNull, "" & RS(2), "")
RS.MoveNext: Counter = Counter + 1
merupakan pengembangan dari perangkat Wend
lunak yang menyediakan fasilitas yang End With
diperlukan untuk membuat program database RS.Close
Set RS = Nothing
berupa keterangan mengenai kumpulan End Sub
sejumlah tabel prosedur tersimpan dan Private Sub Command1_Click()
hubungan relasi antar tabel yang saling If Text1 = "" Or Text2 = "" Or Text3 = "" Then
MsgBox "Isi semuanya dong... .", 0, "Input Cek"
berhubungan dan membentuk suatu program Text1.SetFocus
aplikasi. Exit Sub
End If
Set RS = New ADODB.Recordset
If BARU = True Then
Flowchart Sistem RS.Open "kota", Cn, adOpenDynamic, adLockOptimistic
RS.AddNew
RS(0) = Text1: RS(1) = Text2: RS(2) = Text3
Input RS.Update: RS.Close
data Else
RS.Open "update kota set namakota='" & Text2 & "'," & _
" propinsi='" & Text3 & "' where kodepos='" & Text1 & "'", Cn,
Key In adOpenDynamic, adLockOptimistic
End If
Tabel Tabel InitGrid
kota Transak IsiGrid
sin Bersih
Tabel Text1 = "": Text1.SetFocus
Tarif PROSES End Sub
paket Private Sub Command2_Click()
Unload Me
Tabel Tabel
End Sub
operator klaim
Private Sub Command3_Click()
If Text1 <> "" And Not BARU Then
If MsgBox("Hapus data? Operasi ini tidak dapat dikembalikan!",
vbYesNo + vbCritical, "Hapus") = vbYes Then
Set RS = New ADODB.Recordset
Tampila Laporan RS.Open "Delete FROM kota where kodepos='" & Text1 & "'",
n data Cetak Cn, adOpenDynamic, adLockOptimistic
InitGrid
IsiGrid
Contoh. Listing Program Bersih
Command3.Enabled = False
Form FrmKota.frm End If
End If
End Sub
Dim RS As New ADODB.Recordset Private Sub Form_Activate()
Dim BARU As Boolean Text1.SetFocus: Command3.Enabled = False
InitGrid
Private Sub InitGrid() IsiGrid
With Grid BARU = False
.Cols = 4: .Rows = 1 End Sub
.ColWidth(0) = 400 Private Sub Form_Load()
.ColWidth(1) = 900: .ColWidth(2) = 2300: .ColWidth(3) = 2350 Me.Left = 20: Me.Top = 20
End Sub
Private Sub Grid_Click() Private Sub initGrid1()
If Grid.Rows > 1 Then With Grid
With Grid .Cols = 6
.Col = 1: Text1 = .Text .Rows = 1
.Col = 2: Text2 = .Text .ColWidth(0) = 400
.Col = 3: Text3 = .Text .ColWidth(1) = 800
End With .ColWidth(2) = 2000
BARU = False: Command3.Enabled = True .ColWidth(3) = 2000
End If .ColWidth(4) = 2000
End Sub .ColWidth(5) = 3000
Private Sub Text1_KeyPress(KeyAscii As Integer) .Row = 0
KeyAscii = Asc(UCase(Chr(KeyAscii))) .Col = 0: .Text = "NO"
If KeyAscii = 13 Then Text2.SetFocus .Col = 1: .Text = "KODE POS"
End Sub .Col = 2: .Text = "JENIS PAKET"
.Col = 3: .Text = "TARIF KG 1"
Private Sub Text1_LostFocus() .Col = 4: .Text = "TARIF KG 2"
If Text1 <> "" Then .Col = 5: .Text = "KETERANGAN"
If Len(Text1) = 5 Then End With
Text2 = "": Text3 = "" End Sub
Set RS = New ADODB.Recordset Private Sub InitGrid()
RS.Open "select * from kota where kodepos='" & Text1 & "'", With Grid
Cn, adOpenStatic, adLockReadOnly .Cols = 7: .Rows = 1
If Not (RS.EOF And RS.BOF) Then .ColWidth(0) = 400
Text2 = RS(1) .ColWidth(1) = 1000
Text3 = RS(2) .ColWidth(2) = 2300
BARU = False .ColWidth(3) = 2000
Command3.Enabled = True .ColWidth(4) = 1500
Else .ColWidth(5) = 1500
If MsgBox("Kode pos ini tidak ditemukan." & vbNewLine & .ColWidth(6) = 3000
"Apakah akan ditambahkan baru ?", vbYesNo) = vbYes Then .Row = 0: .Col = 0: .Text = "NO"
Text2.SetFocus: BARU = True .Col = 1: .Text = "KODE POS"
Command3.Enabled = False .Col = 2: .Text = "KOTA TUJUAN"
Else .Col = 3: .Text = "JENIS PAKET"
Text1 = "": Text1.SetFocus .Col = 4: .Text = "TARIF KG 1"
BARU = False .Col = 5: .Text = "TARIF KG 2"
End If .Col = 6: .Text = "KETERANGAN"
End If End With
RS.Close: Set RS = Nothing End Sub
Else Private Sub Combo1_KeyPress(KeyAscii As Integer)
MsgBox "DANGER: Kode pos invalid... ." If KeyAscii = 13 And Combo1.ListIndex > -1 Then Text2.SetFocus
Text1.SetFocus End Sub
End If Private Sub Combo1_LostFocus()
End If If Combo1.ListIndex > -1 Then
Exit Sub If KodeAda Then
Errlo: Set RS = New ADODB.Recordset
MsgBox "Ada error: " & Err.Description RS.Open "select * from tarifpaket where kodepos='" & Text1 &
End Sub "' and jenispaket='" & Trim(Combo1.Text) & "'", Cn, adOpenStatic,
Private Sub Text2_GotFocus() adLockReadOnly
SendKeys "{home}+{end}" If Not (RS.EOF And RS.BOF) Then
End Sub Text2 = RS(2): Text3 = RS(3)
Private Sub Text2_KeyPress(KeyAscii As Integer) Text4 = IIf(RS(4) <> vbNull, RS(4), "")
KeyAscii = Asc(UCase(Chr(KeyAscii))) BARU = False
If KeyAscii = 13 Then Text3.SetFocus Command3.Enabled = True
End Sub Else
Private Sub Text3_GotFocus() Text2 = "": Text3 = "": Text4 = ""
SendKeys "{home}+{end}" BARU = True
End Sub End If
Private Sub Text3_KeyPress(KeyAscii As Integer) Else
KeyAscii = Asc(UCase(Chr(KeyAscii))) BARU = True
If KeyAscii = 13 Then Command1.SetFocus End If
End Sub Text2.SetFocus
Private Sub Bersih() End If
Text2 = "": Text3 = "" End Sub
End Sub
Private Sub Command1_Click()
On Error GoTo Er
Form FrmTarifPaket.frm If Val(Text2) <= 99 Or Val(Text3) <= 99 Then
MsgBox "Tarif paket invalid... ."
Dim RS As New ADODB.Recordset Text2.SetFocus
Dim KodeAda As Boolean Exit Sub
Dim BARU As Boolean End If
If Text1 <> "" Then With Combo1
Dim RS As New ADODB.Recordset .List(0) = "PAKET BIASA"
If KodeAda Then .List(1) = "PAKET OPTIMA"
If BARU Then .List(2) = "KILAT KHUSUS"
SaveNew .ListIndex = 0
Else End With
Set RS = New ADODB.Recordset InitGrid
RS.Open "UPDATE TARIFPAKET SET TARIFPAKET.KG1 IsiGrid
= '" & Text2 & "', TARIFPAKET.KGNEXT = '" & Text3 & "', End Sub
TARIFPAKET.KET = '" & Text4 & "'" & _ Private Sub IsiGrid()
" WHERE (((TARIFPAKET.KODEPOS)='" & Text1 & "') Set RS = New ADODB.Recordset
AND ((TARIFPAKET.JENISPAKET)='" & Trim(Combo1.Text) & RS.Open "SELECT TARIFPAKET.KODEPOS,
"'));", Cn, adOpenDynamic, adLockOptimistic KOTA.NAMAKOTA, TARIFPAKET.JENISPAKET,
If RS.State = adStateOpen Then RS.Close: Set RS = Nothing TARIFPAKET.KG1, TARIFPAKET.KGNEXT,
End If TARIFPAKET.KET " & _
Else "FROM TARIFPAKET INNER JOIN KOTA ON
SaveNew TARIFPAKET.KODEPOS = KOTA.KODEPOS " & _
End If "ORDER BY TARIFPAKET.KODEPOS,
Else TARIFPAKET.JENISPAKET;", Cn, adOpenStatic,
MsgBox "Kode pos invalid... ." adLockReadOnly
Text1.SetFocus With Grid
End If Counter = 1
InitGrid .Row = 0
IsiGrid While Not RS.EOF
initTxt .AddItem Counter
Exit Sub .Row = .Rows - 1
Er: .Col = 1:
MsgBox "Sorry ada error:" & vbNewLine & vbNewLine & .CellAlignment = flexAlignCenterCenter
Err.Description .Text = IIf(RS(0) <> vbNull, RS(0), "")
End Sub .Col = 2:
Private Sub SaveNew() .CellAlignment = flexAlignLeft
Set RS = New ADODB.Recordset .Text = IIf(RS(1) <> vbNull, UCase(RS(1)), "")
RS.Open "tarifpaket", Cn, adOpenDynamic, adLockOptimistic .Col = 3:
RS.AddNew .CellAlignment = flexAlignLeft
RS(0) = Text1: RS(1) = Trim(Combo1.Text) .Text = IIf(RS(2) <> vbNull, RS(2), "")
RS(2) = Text2: RS(3) = Text3: RS(4) = Text4 .Col = 4:
RS.Update: RS.Close: Set RS = Nothing .Text = IIf(RS(3) <> vbNull, RS(3), "0")
End Sub .Col = 5:
Private Sub initTxt() .Text = IIf(RS(4) <> vbNull, RS(4), "0")
Text1 = "": Text2 = "": Text3 = "": Text4 = "": Combo1.ListIndex = 0 .Col = 6:
Label3 = "" .CellAlignment = flexAlignLeft
End Sub .Text = IIf(RS(5) <> vbNull, RS(5), "")
Private Sub Command2_Click() RS.MoveNext
Unload Me Counter = Counter + 1
End Sub Wend
End With
Private Sub Command3_Click() RS.Close
If Text1 <> "" And Not BARU And KodeAda Then End Sub
If MsgBox("Menghapus kode pos " & Text1 & " jenis paket " &
UCase(Combo1) & " ?", vbYesNo + vbCritical + vbDefaultButton2, Private Sub isiGrid1()
"Delete") = vbYes Then Set RS = New ADODB.Recordset
Set RS = New ADODB.Recordset RS.Open "select * from tarifpaket order by kodepos, jenispaket", Cn,
RS.Open "delete from tarifpaket where kodepos='" & Text1 & "' adOpenStatic, adLockReadOnly
and [jenispaket]='" & Trim(Combo1) & "'", Cn, adOpenDynamic, With Grid
adLockOptimistic Counter = 1
If RS.State = adStateOpen Then RS.Close: Set RS = Nothing .Row = 0
Command3.Enabled = False While Not RS.EOF
initTxt .AddItem Counter
InitGrid .Row = .Rows - 1
IsiGrid .Col = 1:
End If .CellAlignment = flexAlignCenterCenter
End If .Text = IIf(RS(0) <> vbNull, RS(0), "")
End Sub .Col = 2:
.CellAlignment = flexAlignLeft
Private Sub Form_Activate() .Text = IIf(RS(1) <> vbNull, RS(1), "")
initTxt .Col = 3:
Text1.SetFocus .Text = IIf(RS(2) <> vbNull, RS(2), "")
End Sub .Col = 4:
.Text = IIf(RS(3) <> vbNull, RS(3), "")
Private Sub Form_Load() .Col = 5:
Me.Left = 20 .CellAlignment = flexAlignLeft
Me.Top = 20 .Text = IIf(RS(4) <> vbNull, RS(4), "")
RS.MoveNext: Counter = Counter + 1 If KeyAscii = 13 Then Text3.SetFocus
Wend End Sub
End With Private Sub Text3_KeyPress(KeyAscii As Integer)
RS.Close If KeyAscii = 13 Then Text4.SetFocus
End Sub End Sub
Private Sub Text4_KeyPress(KeyAscii As Integer)
Private Sub Grid_Click() KeyAscii = Asc(UCase(Chr(KeyAscii)))
If Grid.Rows > 1 Then If KeyAscii = 13 Then Command1.SetFocus
With Grid End Sub
.Col = 1: Text1 = .Text
.Col = 3: Combo1.Text = .Text
.Col = 4: Text2 = .Text Form FrmTrans.frm
.Col = 5: Text3 = .Text
.Col = 6: Text4 = .Text Dim RS As New ADODB.Recordset
.Col = 2: Label3 = .Text Dim vKodeDest, vPaket As String
End With Dim vTarif1, vTarif2 As Double
KodeAda = True Dim Kg2, hTangg As Currency
BARU = False 'Dim Konf As Integer
Command3.Enabled = True Private Sub Combo1_KeyPress(KeyAscii As Integer)
End If If Combo1.ListIndex > -1 And KeyAscii = 13 Then Text12.SetFocus
End Sub End Sub

Private Sub Text1_KeyPress(KeyAscii As Integer) Private Sub Combo1_LostFocus()


If Text1 <> "" And KeyAscii = 13 Then SendKeys "{Tab}" If Text3 <> "" Then
End Sub If Combo1.ListIndex > -1 Then
Dim rsTrf As New ADODB.Recordset
Private Sub Text1_LostFocus() Set rsTrf = New ADODB.Recordset
If Text1 <> "" Then rsTrf.Open "select * from tarifpaket where kodepos='" &
If Len(Text1) = 5 Then vKodeDest & "' and jenispaket='" & Trim(Combo1.Text) & "'", Cn,
Set RS = New ADODB.Recordset adOpenStatic, adLockReadOnly
RS.Open "select * from kota where kodepos = '" & Text1 & "'", If Not (rsTrf.EOF And rsTrf.BOF) Then
Cn, adOpenStatic, adLockReadOnly vTarif1 = rsTrf(2): Text20 = rsTrf(2)
If Not (RS.EOF And RS.BOF) Then vTarif2 = rsTrf(3)
Label3 = UCase(RS(1)) Else
Dim rsCek As New ADODB.Recordset MsgBox "Jenis paket " & Trim(UCase(Combo1)) & vbNewLine &
Set rsCek = New ADODB.Recordset "kota tujuan " & Text4 & " - " & vKodeDest & vbNewLine &
rsCek.Open "select * from tarifpaket where kodepos = '" & "TIDAK DITEMUKAN."
Text1 & "'", Cn, adOpenStatic, adLockReadOnly Text3.SetFocus
If Not (rsCek.EOF And rsCek.BOF) Then End If
KodeAda = True rsTrf.Close: Set rsTrf = Nothing
BARU = False End If
Else End If
KodeAda = False End Sub
BARU = True Private Sub Command1_Click()
End If If Text3 <> "" Then
Command3.Enabled = False If Text11 <> "" Then
Combo1.SetFocus If MsgBox("Simpan transaksi ini ?", vbYesNo, "Simpan") =
rsCek.Close vbYes Then
Set rsCek = Nothing
Else Set RS = New ADODB.Recordset
MsgBox "Kode pos ini tidak ditemukan." & vbNewLine & RS.Open "TRANSAKSI", Cn, adOpenDynamic,
"Periksa pada tabel kode pos." adLockOptimistic
Text1.SetFocus RS.AddNew
End If RS(0) = Text11: RS(1) = DTPicker1.Value
RS.Close RS(2) = Text8: RS(3) = Text1
Set RS = Nothing RS(4) = Text2: RS(5) = Text4
Else RS(6) = Text3: RS(7) = Text5: RS(8) = Text6
MsgBox "Kode pos invalid... ." RS(10) = Text9: RS(9) = Text7: RS(11) = Text8
Text1.SetFocus RS(12) = Text10: RS(13) = Text12
End If RS(14) = 0 + Val(Text14): RS("NILAIBRG") = 0 +
End If Val(Text19)
End Sub RS("HRGTANGG") = 0 + Val(Text13): RS(16) = 0 +
Private Sub Text2_GotFocus() Val(Text20)
SendKeys "{Home}+{End}" RS(17) = 0 + Val(Text21): RS(18) = 0 + Val(Text23)
End Sub RS(19) = Trim(Combo1): RS(20) = 0 + Val(Text24) 'total
Private Sub Text3_GotFocus() RS.Update: RS.Close
SendKeys "{Home}+{End}" Set RS = Nothing
End Sub
Private Sub Text4_GotFocus() FACKT = ""
SendKeys "{Home}+{End}" FACKT = Text11
End Sub 'Unload CetakTrans
Private Sub Text2_KeyPress(KeyAscii As Integer)
Konf = MsgBox("Cetak langsung ke printer ? Masukkan kertas.",
vbYesNo) Private Sub Text14_Change()
If Val(Text14) > 0 Then
'DataEnvPos.ConnPos.ConnectionString = dbLoc Text20 = vTarif1
If DataEnvPos.ConnPos.State = adStateOpen Then Call Tarif
DataEnvPos.ConnPos.Close Else
Set ConnPos = Nothing Text20 = 0
GoTo Lop Text21 = 0
Else End If
Lop: End Sub
DataEnvPos.ConnPos.ConnectionString =
Cn.ConnectionString Private Sub Text14_LostFocus()
DataEnvPos.ConnPos.Open If Text14 = "" Then Text14 = 0
End If End Sub
DataEnvPos.CetakTrans FACKT
CetakTrans.Orientation = rptOrientLandscape Private Sub Tarif()
If Konf = vbYes Then Kg2 = 0
On Error Resume Next If Val(Text14) = 1 Then
CetakTrans.PrintReport False Text21 = 0
CetakTrans.Refresh Else
Unload CetakTrans If Val(Text14) > 1 Then
Else Kg2 = Val(Text14) - 1
On Error Resume Next Text21 = Val(vTarif2) * Val(Kg2)
CetakTrans.Refresh End If
End If End If
End If End Sub
initAll
Else Private Sub Text19_Change()
MsgBox "Nomor faktur kosong." hTangg = 0
End If If Val(Text19) > 0 Then
Else hTangg = 0.0024 * Val(Text19)
MsgBox "Kode pos tujuan kosong/invalid." Text13 = Format(hTangg, "#")
End If hitungTot
End Sub Else
Text13 = 0
Private Sub Command2_Click() End If
Unload Me End Sub
End Sub
Private Sub Text2_GotFocus()
Private Sub Form_Activate() SendKeys "{Home}+{End}"
Text1.SetFocus End Sub
initAll Private Sub Text2_KeyPress(KeyAscii As Integer)
End Sub KeyAscii = Asc(UCase(Chr(KeyAscii)))
If KeyAscii = 13 Then Text3.SetFocus
Private Sub Form_Load() End Sub
Me.Left = 20: Me.Top = 20
Label2.Caption = UCase(vCity) & " - " & vCode & " " Private Sub Text20_Change()
With Combo1 hitungSub
.List(0) = "PAKET BIASA" End Sub
.List(1) = "PAKET OPTIMA"
.List(2) = "KILAT KHUSUS" Private Sub Text21_Change()
.ListIndex = 0 hitungSub
End With End Sub
End Sub
Private Sub hitungSub()
Private Sub initAll() total = 0: subtotal = 0: ppn = 0
Text1 = "": Text2 = "": Text3 = "": Text4 = "": Text5 = "": Text6 = "": total = Val(Text20) + Val(Text21)
Text7 = "": Text8 = "" subtotal = Val(total) + (0.024 * Val(total))
Text9 = "": Text10 = "": Text11 = "": Text12 = "": Text13 = 0: Text14 ppn = ((1 / 100) * Val(subtotal))
= 0: Text15 = 0: Text16 = 0 Text22 = Val(subtotal) '+ Val(ppn)
Text17 = 0: Text18 = 0: Text19 = 0: Text20 = 0: Text21 = 0: Text22 = Text22 = Format(Text22, "#")
0: Text23 = 0: Text24 = 0 Text23 = Format(ppn, "#")
DTPicker1.Value = Date End Sub
End Sub
Private Sub hitungTot()
Private Sub Text1_GotFocus() tot = 0
SendKeys "{Home}+{End}" tot = Val(Text22) + Val(Text23) + Val(hTangg)
End Sub Text24 = Format(tot, "####")
Private Sub Text1_KeyPress(KeyAscii As Integer) End Sub
KeyAscii = Asc(UCase(Chr(KeyAscii)))
If KeyAscii = 13 Then Text2.SetFocus Private Sub Text22_Change()
End Sub hitungTot
End Sub frmCariKodePos.Show 1
End If
Private Sub Text23_Change() End Sub
hitungTot Private Sub Text9_GotFocus()
End Sub SendKeys "{Home}+{End}"
End Sub
Private Sub Text3_GotFocus() Private Sub Text9_KeyPress(KeyAscii As Integer)
SendKeys "{Home}+{End}" KeyAscii = Asc(UCase(Chr(KeyAscii)))
End Sub If KeyAscii = 13 Then Text10.SetFocus
Private Sub Text3_KeyPress(KeyAscii As Integer) End Sub
If KeyAscii = 13 And Text3 <> "" Then Text4.SetFocus Private Sub Text10_GotFocus()
If KeyAscii = 13 And Text3 = "" Then SendKeys "{Home}+{End}"
Kodep = True End Sub
frmCariKodePos.Show 1 Private Sub Text10_KeyPress(KeyAscii As Integer)
End If If KeyAscii = 13 Then Combo1.SetFocus
End Sub End Sub

Private Sub Text3_LostFocus() Private Sub Text12_GotFocus()


If Text3 <> "" Then SendKeys "{Home}+{End}"
If Len(Text3) = 5 Then End Sub
Set RS = New ADODB.Recordset Private Sub Text12_KeyPress(KeyAscii As Integer)
RS.Open "select * from kota where kodepos = '" & Text3 & "'", KeyAscii = Asc(UCase(Chr(KeyAscii)))
Cn, adOpenStatic, adLockReadOnly If KeyAscii = 13 Then Text14.SetFocus
If Not (RS.EOF And RS.BOF) Then End Sub
Text4 = RS(1): vKodeDest = Text3: noFaktur Private Sub Text14_GotFocus()
Else SendKeys "{Home}+{End}"
MsgBox "Kode pos ini tidak ditemukan." & vbNewLine & End Sub
"Kosongi dan tekan Enter utk. mencari." Private Sub Text14_KeyPress(KeyAscii As Integer)
Text3.SetFocus Dim strAngka As String
End If strAngka = "0123456789."
RS.Close: Set RS = Nothing If KeyAscii > 26 Then
Else If InStr(strAngka, Chr(KeyAscii)) = 0 Then KeyAscii = 0
MsgBox "DANGER: Kode pos invalid... ." End If
Text3.SetFocus If KeyAscii = 13 Then Text19.SetFocus
End If End Sub
End If Private Sub Text19_GotFocus()
End Sub SendKeys "{Home}+{End}"
Private Sub Text4_GotFocus() End Sub
KeyAscii = Asc(UCase(Chr(KeyAscii))) Private Sub Text19_KeyPress(KeyAscii As Integer)
SendKeys "{Home}+{End}" KeyAscii = Asc(UCase(Chr(KeyAscii)))
End Sub If KeyAscii = 13 Then Command1.SetFocus
Private Sub Text4_KeyPress(KeyAscii As Integer) End Sub
If KeyAscii = 13 Then Text5.SetFocus Private Sub Text20_GotFocus()
End Sub SendKeys "{Home}+{End}"
Private Sub Text5_GotFocus() End Sub
SendKeys "{Home}+{End}" Private Sub Text20_KeyPress(KeyAscii As Integer)
End Sub KeyAscii = Asc(UCase(Chr(KeyAscii)))
Private Sub Text5_KeyPress(KeyAscii As Integer) If KeyAscii = 13 Then Text21.SetFocus
If KeyAscii = 13 Then Text6.SetFocus End Sub
End Sub Private Sub Text21_GotFocus()
Private Sub Text6_GotFocus() SendKeys "{Home}+{End}"
SendKeys "{Home}+{End}" End Sub
End Sub Private Sub Text21_KeyPress(KeyAscii As Integer)
Private Sub Text6_KeyPress(KeyAscii As Integer) KeyAscii = Asc(UCase(Chr(KeyAscii)))
KeyAscii = Asc(UCase(Chr(KeyAscii))) If KeyAscii = 13 Then Text22.SetFocus
If KeyAscii = 13 Then Text7.SetFocus End Sub
End Sub Private Sub Text22_GotFocus()
Private Sub Text7_GotFocus() SendKeys "{Home}+{End}"
SendKeys "{Home}+{End}" End Sub
End Sub Private Sub Text22_KeyPress(KeyAscii As Integer)
Private Sub Text7_KeyPress(KeyAscii As Integer) KeyAscii = Asc(UCase(Chr(KeyAscii)))
KeyAscii = Asc(UCase(Chr(KeyAscii))) If KeyAscii = 13 Then Text23.SetFocus
If KeyAscii = 13 Then Text8.SetFocus End Sub
End Sub Private Sub Text23_GotFocus()
Private Sub Text8_GotFocus() SendKeys "{Home}+{End}"
SendKeys "{Home}+{End}" End Sub
End Sub Private Sub Text23_KeyPress(KeyAscii As Integer)
Private Sub Text8_KeyPress(KeyAscii As Integer) KeyAscii = Asc(UCase(Chr(KeyAscii)))
'If KeyAscii = 13 Then Text9.SetFocus If KeyAscii = 13 Then Text24.SetFocus
If KeyAscii = 13 And Text8 <> "" Then Text9.SetFocus End Sub
If KeyAscii = 13 And Text8 = "" Then Private Sub Text24_GotFocus()
Kodep = False SendKeys "{Home}+{End}"
End Sub Gambar .. Tampilan Menu Utama
Private Sub Text24_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then Command1.SetFocus Dalam menu utama terdiri dari :
End Sub a. Menu Kodepos
Private Sub noFaktur() Menu ini berisi program untuk
On Error GoTo Eraaa
Dim rsKwit As ADODB.Recordset menyimpan data kodepos.
Set rsKwit = New ADODB.Recordset b. Menu Tarif Paket
rsKwit.Open "select max(right(NOfaktur,7)) from transaksi", Cn,
adOpenStatic, adLockReadOnly
Menu ini berisi program untuk
If Not (rsKwit.EOF And rsKwit.BOF) Then menyimpan data harga paket, jenis paket
X = CStr(Val(Right(rsKwit(0), 7)) + 1) yang ditawarkan oleh perusahaah.
If X > 9999999 Then X = "0000001"
If Len(X) = 1 Then X = "000000" & X c. Menu Pengiriman Paket
If Len(X) = 2 Then X = "00000" & X Menu ini berisi program untuk mencatat
If Len(X) = 3 Then X = "0000" & X transaksi harian paket. Serta sebagai nota
If Len(X) = 4 Then X = "000" & X
If Len(X) = 5 Then X = "00" & X pembayaran pelanggan.
If Len(X) = 6 Then X = "0" & X d. Menu Pengajuan Klaim
Text11 = X
Else
Meniu ini berisi program transaksi klaim
Text11 = "0000001" untuk mengetahui seberapa besar nilai
End If ganti rugi perusahaan pada saat
rsKwit.Close: Set rsKwit = Nothing
Exit Sub pengiriman paket rusak atau hilang.
Eraaa: Disini perusahaan akan mengganti 10 kali
Text11 = "0000001" lipat dari biaya pengiriman dan telah
End Sub
diketahui nilai barang.
4. Hasil dan Pembahasan e. Laporan
Dalam program ini menu utama 1. Laporan Transaksi Pengiriman Paket
merupakan keseluruhan program yang ada. Laporan ini digunakan untuk melihat
Adapun didalam menu utama terdapat beberapa hasil nota paket tiap harinya.
pilihan yang masing-masing pilihan terdapat 2. Laporan Klaim
submenu-submenu yang didalamnya terdapat Laporan ini digunakanuntuk melihat
juga pilihan yang siap untuk dijalankan. Maka hasil pangiriman yang mengalami
dalam bab ini disajikan bagian-bagian dari kerusakan atau hilang.
aplikasi program data pengiriman paket, adalah 3. Laporan Kodepos
sebagai berikut : Laporan ini digunakan untuk
1. Menjalankan program melihat kodepos dan kota.
Tahap awal menjalankan program 4. Laporan Tarif Paket
pengolahan data pengiriman barang adalah Laporan ini digunakan untuk
sebagai berikut : melihat data terif dan jenis
a. Aktifkan system windows pengiriman paket.
b. Dari start pilih program visual
Basic 6.0 f. Menu Setting Kota Asal
c. Kemudian jalankan program Menu ini berisi program untuk
Pengolahan data pengiriman paket mengganti kota asal.

Tampilan Menu Setting Kota Asal


g. Menu Setting Password Cara kerja :
Menu ini berisi program untuk - Isi textbox kodepos, bila kodepos sudah ada
mengganti password. maka kota akan muncul.
- Pilih option jenis paket, apabila jenis paket
sudah ada maka jenis paket akan
muncul.Tarif Kg1, Kg berikutnya dan
keterangan akan muncul.
- Klik save untuk menyimpan data tarif paket.
3. Tampilan Menu Transaksi Pengiriman
Paket
Menu transaksi berfungsi untuk merekam
data-data suatu proses antar transaksi
yang berhubungan dengan pengiriman
paket. Berikut tampilan menu transaksi
pengiriman paket :
Gambar . Tampilan Setting Password

2. Tampilan Inputan
a. Tampilan Masukan Data Kodepos

Gambar. Transaksi Pengiriman Paket


Gambar .Tampilan masukan data kodepos
Cara kerja :
Cara kerja : - Isi textbox nama penerima, alamat penerima,
- Isi textbox kodepos, apabila kodepos sudah ada kodepos penerima, jika kodepos sudah ada
maka data kodepos yang sudah ada akan maka kota penerima akan muncul, isi telepon
muncul, tetapi bila kodepos belum ada maka penerima.
textbox kodepos, kota, propinsi siap diisi. - Isi textbox nama pengirim, alamat pengirim,
- Setelah semua terisi dengan benar, klik save kodepos pengirim, jika kodepos sudah ada
untuk menyimpanya, lalu klik tutup untuk maka kota pengirim akan muncul, isi telepon
keluar dan kembali ke menu utama. pengirim.
b. Tampilan masukan Data Tarif Paket - Pada option jenis paket terdapat tiga pilihan
yaitu paket biasa, kilat khusus dan paket
optima. Pilih salah satu jenis paket maka Kg1
dan Kg berikutnya akan muncul. Lalu isi
pada textbox isi barang, berat barang dan
harga nilai barang.
- Klik command simpan bila data sudah terisi
dengan benar, apabila ingin mencetak pilih
yes.
4. Tampilan Menu Transaksi Klaim
Menu ini berisi program transaksi klaim
Gambar IV.12. masukan data tarif paket untuk mengetahui seberapa besar nilai ganti
rugi perusahaan pada saat pengiriman barang
rusak atau hilang. Disini perusahaan akan
mengganti 10 kali lipat dari biaya pengiriman
dan telah diketahui nilai barang.

Gambar IV.18. Laporan Hasil Nota Paket

E. Simulasi Perhitungan Pengiriman Paket

Gambar. Tampilan Transaksi Klaim 1. Diketahui : pengiriman barang dengan berat


barang 10 kg, tujuan Surabaya, berisikan kain
Cara kerja : seharga Rp. 100.000,00. Jenis pengiriman
- Isi textbox no faktur. Apabila data sudah ada paket biasa.
maka data akan muncul dan langsung akan Berat kg1 tujuan Solo- Surabaya Rp.1.800,00.
diketahui nilai ganti ruginya. Kg selanjutnya Rp.1.300,00.
- Klik simpan untuk menyimpan transaksi Biaya Pengiriman :
klaim, command tutup untuk keluar dan - Bea Kirim = tarif kirim + harga tanggungan
kembali ke menu utama. ongkos kirim (0,24% x 10 x tarif kirim).
5. Tampilan Menu Laporan - Harga tanggungan nilai barang = 0,24% x
Untuk menu laporan digunakan untuk mencetak harga barang sebenarnya.
data dalam bentuk kertas yang dicetak melelui - PPN 1% = 1% x Bea kirim
printer. Pada menu laporan ini terdiri dari 4(empat) Bea kirim
submenu yang terdiri dari : = Rp. 13.500 + ( 0,24% x 10 x 13.500)
a. Submenu laporan data kodepos = Rp. 13.824,00
b. Submenu laporan data tarif paket
c. Submenu laporan hasil nota paket PPN 1% =1% x Rp. 13.824
d. Submenu laporan transaksi klaim = Rp. 138,24 +
Tampilan untuk submenu laporan data kodepos Biaya Kirim = Rp. 13.962,24
adalah seperti gambar dibawah ini: Nilai Barang = 0,24% x Rp. 100000
= Rp. 240,00+
Total Bayar = Rp. 14.202,24

Alur Pengiriman Paket


Teknis penerimaan dan pengiriman paket
antara lain :
1. Harus Bagian Administrasi
- Mengisi blangko paket
- Barang ditimbang kemudian berat
timbangan dimasukkan kedalam
Gambar IV.15. Tampilan Laporan program komputer, bea pengiriman
Kodepos dan kota akan muncul sesuai dengan tariff yang
Tampilan untuk submenu laporan data tarif berlaku.
paket adalah seperti gambar dibawah ini: 2. Pemeriksaan kantor tujuan
- lamat tujuan diperiksa apakah sudah
Gambar IV.17. Tampilan Submenu Hasil termasuk jaringan paket barang.
Nota Paket 3. Tempat tinggal penerima
- Bila ima tidak ditemukan atau pindah Saran
barang akan dikembalikan pada pengirim Setelah penulis mengadakan penelitian maka
disertai dengan surat kembali. penulis bermaksud untuk memberikan saran-
4. Paket barang tanpa nama dan alamat saran dalam rangka peningkatan dan
pengirim: perkembangan pemaketan di PT. Pos
- Dapat diterima Indonesia Surakarta khususnya adalah sebagai
- Diluar alamat pengirim 1 dicatat nama berikut :
kantor asal secara lengkap. 1. Sebaiknya sistem yang masih dilakukan
- Nama/alamat pengirim yang lengkap secara manual diganti dengan sistem
dicatat nama kantor asal secara lengkap. komputerisasi, agar dalam pengolahan
5. Waktu pengiriman: datanya lebih cepat, tepat dan efisien.
- Jadwal yg dibuat diatas papan tulis pada 2. Pembelajaran dan sosialisasi tentang
tabel merangkap sbg pengumuman teknologi dan informasi sebaikya
publik. direalisasikan dalam PT. Pos Indonesia,
- Waktu tempuh 24 jam dalam hubungan supaya dapat lebih maju dalam dunia
langsung, artinya antar tempat usaha jasa dalam negeri maupun luar
yang dihubungkan alat angkutan secara negeri .
langsung. 48 jam dalam hubungan tak Segala saran maupun kritik yang
langsung, artinya tempat yang sifatnya membangun sangat penulis harapkan
dihubungkan alat angkutan secara tidak agar makalah ini lebih sempurna. Penulis
langsung. berharap makalah ini dapat berguna bagi
- Menghitung waktu 24 jam atau 48 jam semua pihak yang membutuhkan dan yang
tersebut diatas waktu tutupan. bersangkutan.
Kesempatan pertama berikutnya setelah Akhir kata, penulis menyadari bahwa dalam
pengirim barang yang bersangkutan dilket makalah ini masih jauh dari sempurna.
sampai penerimaanya oleh penerima. Semoga apa yang penulis lakukan akan
menghasilkan sesuatu yang baik demi
5. Kesimpulan kemajuan Politeknik Pratama Mulia
Setelah memberikan uraian program Surakarta.
aplikasi dalam makalah ini, maka penulis dapat
mengambil kesimpulan : DAFTAR PUSTAKA
1. Pengiriman paket yang dilakukan dengan Pemrograman Visual II Politeknik Pratama
cara komputerisasi akan lebih efektif dan Mulia Surakarta, Penerbit Politeknik Pratama
efisien dalam segi tenaga maupun waktu Mulia Surakarta, 2005
dibandingkan dengan cara manual . Agus J, Alam, M, Belajar Sendiri Manajemen
2. Program yang penulis susun dapat digunakan Database dengan Microsoft Visual Basic versi
sebagai alat yang dapat menghasilkan 6.0, P.T Elek Media Komputindo, 2002
laporan yang lebih cepat, akurat dan tepat. Djoko Pramono, Menguasai Microsoft Visual
3. Dengan penerapan system komputerisasi Basic 6.0, P.T Elek Media Komputindo, Jakarta.
yang terpadu dalam pengiriman paket maka Drs.Ario Suryo Kusumo, Pemrograman
diperlukan juga biaya yang lebih Database dengan Microsoft Visual Basic 6.0,
dibandingkan dengan cara manual. P.T Elek Media Komputindo Komplek Gramedia
– Jakarta.

Anda mungkin juga menyukai