L A M P I R A N
SURAT KETERANGAN Hasil Uji Program Tugas Akhir Yang bertandatangan dibawah ini, menerangkan bahwa Mahasiswa Tugas Akhir Program D3 Teknik Informatika : Nama Mahasiswa : MUHAMMAD IQBAL Nomor Induk Mahasiswa : 112406170 Program Studi : D3 TEKNIK INFORMATIKA Judul Tugas Akhir : PERANCANGAN SISTIM INFORMASI APOTEK SINAR FARMA GLUGUR RIMBUN MENGGUNAKAN MICROSOFT VISUALBASIC 6.0 Telah melaksanakan tes program Tugas Akhir Mahasiswa tersebut diatas pada tanggal: Juni 2014 Dengan Hasil : SUKSES / GAGAL Demikian diterangkan untuk digunakan melengkapi syarat pendaftaran Ujian Meja Hijau Tugas Akhir Mahasiswa bersangkutan di Departemen Matematika FMIPA USU Medan. Medan, Juni 2014 Dosen Pembimbing Program Studi D3 Teknik Informatika Drs. Faigiziduhu Bu ulolo, M.Si NIP. 19531218 198003 1 003
KEMENTERIAN PENDIDIKAN DAN KEBUDAYAAN UNIVERSITAS SUMATERA UTARA FAKULTAS MATEMATIKA DAN ILMU PENGETAHUAN ALAM Jl. Bioteknologi No. 1 Kampus USU Padang Bulan Medan-20155 Telp. (061) 8214290, 8211212, 8211414 Fax. (061) 821429 Kartu Bimbingan Tugas Akhir Mahasiswa Nama Mahasiswa : Muhammad Iqbal Nomor Induk Mahasiswa : 112406170 Program Studi : D3 Teknik Informatika Judul : Perancangan Sistim Informasi Apotek Sinar Farma Glugur Rimbun Menggunakan Microsoft Visual Basic 6.0 Dosen Pembimbing : Drs. Faigiziduhu Bu'ulolo, M.Si Tanggal Mulai Bimbingan : Maret 2014 Tanggal Selesai Bimbingan : Juni 2014 No Tanggal Bimbingan Pembahasan Asistensi Mengenai Bab Paraf Dosen Pembimbing Keterangan 1 2 3 4 5 6 7 * Kartu ini harap dikembalikan ke Departemen Matematika bila bimbingan Mahasiswa telah selesai Diketahui Program Studi D3 Teknik Informatika FMIPA USU Ketua, Disetujui, Pembimbing Utama/ Penanggung Jawab Dr. Elly Rosmaini, M.Si Drs. Faigiziduhu Bu'ulolo, M.Si NIP. 19600520 198503 2 002 NIP. 19531218 198003 1 003
LISTING PROGRAM Form Menu Utama Dim shari As String Dim ahari Dim judul As String Private Sub Form_Load() ahari = Array("Minggu /", "Senin /", "Selasa /", "Rabu /", "Kamis /", "Jumat /", "Sabtu /") lblhari.caption = Day(Now) judul = "Aplikasi Apotek Sinar Farma Glugur Rimbun" Me.Caption = judul Private Sub timerhari_timer() shari = ahari(abs(weekday(date) - 1)) lblhari.caption = "" & shari & "" Private Sub timerjam_timer() lbljam.caption = Time lbljam.caption = Format(Time, "HH:MM:SS") If lbljam.caption < Format(Time, "11:00:00") Then lblselamat.caption = "--- Selamat Pagi" ElseIf lbljam.caption < Format(Time, "15:00:00") Then lblselamat.caption = "--- Selamat Siang"
ElseIf lbljam.caption < Format(Time, "19:00:00") Then lblselamat.caption = "--- Selamat Sore" ElseIf lbljam.caption <= Format(Time, "23:59:59") Then lblselamat.caption = "--- Selamat Malam" Private Sub timertanggal_timer() lbltanggal.caption = Date lbltanggal.caption = Format(Date, "dd MMMM YYYY") Private Sub cmdkeluar_click() If MsgBox("Keluar Dari Aplikasi?", vbyesno + vbcritical, "Keluar") = vbno Then Cancel = 1 Else MsgBox "Terima Kasih Sudah Berkunjung" End Private Sub cmdadmin_click() Frmlogin.Show frmenuutama.hide
Form Login Public Conn As New ADODB.Connection Public rs As New ADODB.Recordset Sub koneksi() Set Conn = New ADODB.Connection Set rs = New ADODB.Recordset Conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\PerkuLiahan\TA IqbaL\apotek.mdb" Sub bersih() Text1 = "" Text2 = "" Private Sub cmdlogin_click() Call koneksi If txtnama = "" Or txtpassword = "" Then Else MsgBox "Data Login Belum Lengkap" txtpassword.enabled = False txtnama.enabled = False Exit Sub rs.open "Select * from Login where Nama ='" & txtnama & "' and Password='" & txtpassword & "'", Conn If rs.eof Then MsgBox "Login Salah!"
Call bersih txtnama.setfocus Else MsgBox "Login Berhasil!" frmdataobat.show Frmlogin.Hide Call bersih Private Sub cmdquit_click() Pesan = MsgBox("Batal Login?", vbyesno) If Pesan = vbyes Then End Form Data Obat Private Sub About_Click(Index As Integer) frmabout.show frmdataobat.hide Private Sub Botol_Click() frmbotol.show frmdataobat.hide
Private Sub Kapsul_Click() frmkapsul.show frmdataobat.hide Private Sub Cream_Click() frmcream.show frmdataobat.hide Private Sub Tablet_Click() frmtablet.show frmdataobat.hide Private Sub Penjualan_Click() frmtransaksipenjualan.show frmdataobat.hide Private Sub Logout_Click() frmlogout.show frmdataobat.hide Private Sub Supplier_Click()
frmsupplier.show frmdataobat.hide Private Sub Data_Admin_Click() frmdatadmin.show frmdataobat.hide Form Data Admin Private Sub cmdback_click() Unload Me frmdataobat.show Form Tablet Private Sub cmdfind_click() Adodc1.Recordset.Find "Kode='" + txtkode.text + "'",, adsearchforward, 1 If Not Adodc1.Recordset.EOF Then Else txtkode.text = Adodc1.Recordset!Kode txtnamaobat.text = Adodc1.Recordset!NamaObat txthargabeli.text = Adodc1.Recordset!HargaBeli txthargajual.text = Adodc1.Recordset!HargaJual txtstok.text = Adodc1.Recordset!stok MsgBox "Maaf, Data Tidak Ditemukan!"
Private Sub cmdhapus_click() If MsgBox("Yakin Ingin Menghapus Data?", vbquestion + vbokcancel, "konfirmasi") = vbok Then Adodc1.Recordset.Delete Private Sub cmdedit_click() cmdtutup.visible = True cmdclean.visible = True cmdfind.visible = True cmdsimpan.visible = False cmdupdate.visible = True txtkode.enabled = True Private Sub cmdsimpan_click() Adodc1.Recordset.AddNew Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text
Adodc1.Recordset.Update Adodc1.Refresh Private Sub cmdclean_click() txtkode = " " txtnamaobat = " " txthargabeli = " " txthargajual = " " txtstok = " " txtkode.setfocus Private Sub cmdupdate_click() Update = MsgBox("Apakah anda yakin akan mengupdate data ini?", vbquestion + vbyesno) If Update = vbyes Then Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text Adodc1.Recordset.Update Adodc1.Refresh MsgBox "Update Obat Tablet OK!"
Private Sub cmdtutup_click() frmdataobat.show Unload Me Form Botol Private Sub cmdfind_click() Adodc1.Recordset.Find "Kode='" + txtkode.text + "'",, adsearchforward, 1 If Not Adodc1.Recordset.EOF Then Else txtkode.text = Adodc1.Recordset!Kode txtnamaobat.text = Adodc1.Recordset!NamaObat txthargabeli.text = Adodc1.Recordset!HargaBeli txthargajual.text = Adodc1.Recordset!HargaJual txtstok.text = Adodc1.Recordset!stok MsgBox "Maaf, Data Tidak Ditemukan!" Private Sub cmdhapus_click() If MsgBox("Yakin Ingin Menghapus Data?", vbquestion + vbokcancel, "konfirmasi") = vbok Then Adodc1.Recordset.Delete
Private Sub cmdedit_click() cmdtutup.visible = True cmdclean.visible = True cmdfind.visible = True cmdsimpan.visible = False cmdupdate.visible = True txtkode.enabled = True Private Sub cmdsimpan_click() Adodc1.Recordset.AddNew Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text Adodc1.Recordset.Update Adodc1.Refresh Private Sub cmdclean_click() txtkode = " " txtnamaobat = " "
txthargabeli = " " txthargajual = " " txtstok = " " txtkode.setfocus Private Sub cmdupdate_click() Update = MsgBox("Apakah anda yakin akan mengupdate data ini?", vbquestion + vbyesno) If Update = vbyes Then Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text Adodc1.Recordset.Update Adodc1.Refresh MsgBox "Update Obat Botol OK!" Private Sub cmdtutup_click() frmdataobat.show Unload Me
Form Cream Private Sub cmdfind_click() Adodc1.Recordset.Find "Kode='" + txtkode.text + "'",, adsearchforward, 1 If Not Adodc1.Recordset.EOF Then Else txtkode.text = Adodc1.Recordset!Kode txtnamaobat.text = Adodc1.Recordset!NamaObat txthargabeli.text = Adodc1.Recordset!HargaBeli txthargajual.text = Adodc1.Recordset!HargaJual txtstok.text = Adodc1.Recordset!stok MsgBox "Maaf, Data Tidak Ditemukan!" Private Sub cmdhapus_click() If MsgBox("Yakin Ingin Menghapus Data?", vbquestion + vbokcancel, "konfirmasi") = vbok Then Adodc1.Recordset.Delete Private Sub cmdedit_click() cmdtutup.visible = True cmdclean.visible = True cmdfind.visible = True
cmdsimpan.visible = False cmdupdate.visible = True txtkode.enabled = True Private Sub cmdsimpan_click() Adodc1.Recordset.AddNew Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text Adodc1.Recordset.Update Adodc1.Refresh Private Sub cmdclean_click() txtkode = " " txtnamaobat = " " txthargabeli = " " txthargajual = " " txtstok = " " txtkode.setfocus Private Sub cmdupdate_click()
Update = MsgBox("Apakah anda yakin akan mengupdate data ini?", vbquestion + vbyesno) If Update = vbyes Then Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text Adodc1.Recordset.Update Adodc1.Refresh MsgBox "Update Obat Cream OK!" Private Sub cmdtutup_click() frmdataobat.show Unload Me Form Kapsul Private Sub cmdfind_click() Adodc1.Recordset.Find "Kode='" + txtkode.text + "'",, adsearchforward, 1 If Not Adodc1.Recordset.EOF Then txtkode.text = Adodc1.Recordset!Kode txtnamaobat.text = Adodc1.Recordset!NamaObat txthargabeli.text = Adodc1.Recordset!HargaBeli txthargajual.text = Adodc1.Recordset!HargaJual
txtstok.text = Adodc1.Recordset!stok Else MsgBox "Maaf, Data Tidak Ditemukan!" Private Sub cmdhapus_click() If MsgBox("Yakin Ingin Menghapus Data?", vbquestion + vbokcancel, "konfirmasi") = vbok Then Adodc1.Recordset.Delete Private Sub cmdedit_click() cmdtutup.visible = True cmdclean.visible = True cmdfind.visible = True cmdsimpan.visible = False cmdupdate.visible = True txtkode.enabled = True Private Sub cmdsimpan_click() Adodc1.Recordset.AddNew Adodc1.Recordset!Kode = txtkode.text
Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text Adodc1.Recordset.Update Adodc1.Refresh Private Sub cmdclean_click() txtkode = " " txtnamaobat = " " txthargabeli = " " txthargajual = " " txtstok = " " txtkode.setfocus Private Sub cmdupdate_click() Update = MsgBox("Apakah anda yakin akan mengupdate data ini?", vbquestion + vbyesno) If Update = vbyes Then Adodc1.Recordset!Kode = txtkode.text Adodc1.Recordset!NamaObat = txtnamaobat.text Adodc1.Recordset!HargaBeli = txthargabeli.text Adodc1.Recordset!HargaJual = txthargajual.text Adodc1.Recordset!stok = txtstok.text
Adodc1.Recordset.Update Adodc1.Refresh MsgBox "Update Obat Kapsul OK!" Private Sub cmdtutup_click() frmdataobat.show Unload Me Form Supplier Private Sub cmdfind_click() Adodc1.Recordset.Find "KodeSupplier='" + txtkodesupplier.text + "'",, adsearchforward, 1 If Not Adodc1.Recordset.EOF Then Else txtkodesupplier.text = Adodc1.Recordset!KodeSupplier txtnamasupplier.text = Adodc1.Recordset!NamaSupplier txtalamat.text = Adodc1.Recordset!Alamat txttelepon.text = Adodc1.Recordset!Telepon MsgBox "Maaf, Data Tidak Ditemukan!" Private Sub cmdhapus_click()
If MsgBox("Yakin Ingin Menghapus Data?", vbquestion + vbokcancel, "konfirmasi") = vbok Then Adodc1.Recordset.Delete Private Sub cmdedit_click() cmdtutup.visible = True cmdclean.visible = True cmdfind.visible = True cmdsimpan.visible = False cmdupdate.visible = True txtkodesupplier.enabled = True Private Sub cmdsimpan_click() Adodc1.Recordset.AddNew Adodc1.Recordset!KodeSupplier = txtkodesupplier.text Adodc1.Recordset!NamaSupplier = txtnamasupplier.text Adodc1.Recordset!Alamat = txtalamat.text Adodc1.Recordset!Telepon = txttelepon.text Adodc1.Recordset.Update Adodc1.Refresh
Private Sub cmdclean_click() txtkodesupplier = " " txtnamasupplier = " " txtalamat = " " txttelepon = " " txtkodesupplier.setfocus Private Sub cmdupdate_click() Update = MsgBox("Apakah anda yakin akan mengupdate data ini?", vbquestion + vbyesno) If Update = vbyes Then Adodc1.Recordset!KodeSupplier = txtkodesupplier.text Adodc1.Recordset!NamaSupplier = txtnamasupplier.text Adodc1.Recordset!Alamat = txtalamat.text Adodc1.Recordset!Telepon = txttelepon.text Adodc1.Recordset.Update Adodc1.Refresh MsgBox "Update Data Supplier OK!" Private Sub cmdtutup_click() frmdataobat.show Unload Me Form Penjualan
Dim caridata As String Private Sub Command4_Click() If MsgBox("Keluar Dari Transaksi?", vbyesno + vbcritical, "Keluar") = vbno Then Cancel = 1 Else MsgBox "Terima Kasih Sudah Berkunjung" frmdataobat.show frmtransaksipenjualan.hide Private Sub Command5_Click() frmpenghitungobat.show Private Sub Command6_Click() caridata = InputBox("Masukkan Nama Obat", "Cari Data") If rs.state = adstateopen Then rs.close rs.open "select * from Transaksi where NamaObat='" & caridata & "'", con, adopendynamic, adlockoptimistic Set DataGrid1.DataSource = rs Private Sub bukabarang() If rs.state = adstateopen Then rs.close
rs.open "select * from Transaksi ", con, adopendynamic, adlockoptimistic Set DataGrid1.DataSource = rs Private Sub tampilbarang() With rs Text1.Text = IIf(.BOF Or.EOF, "", IIf(IsNull(!KodeObat), "",!KodeObat)) Text2.Text = IIf(.BOF Or.EOF, "", IIf(IsNull(!NamaObat), "",!NamaObat)) Text3.Text = IIf(.BOF Or.EOF, "", IIf(IsNull(!JenisObat), "",!JenisObat)) Text4.Text = IIf(.BOF Or.EOF, "", IIf(IsNull(!HargaObat), "",!HargaObat)) Text5.Text = IIf(.BOF Or.EOF, "", IIf(IsNull(!JumlahObat), "",!JumlahObat)) End With Private Sub Command7_Click() bukabarang tampilbarang Private Sub Form_Load() 'panggil procedure konek konekdb 'seleksi tabel
Penjualan 'konekkan dengan object rs bukabarang tampilbarang Set DataGrid1.DataSource = rs 'tambah data Private Sub Command1_Click() Text1.Text = "" Text2.Text = "" Text3.Text = "" Text4.Text = "0" Text5.Text = "0" Text1.SetFocus 'simpan data Private Sub Command2_Click() Call insert(text1.text, Text2.Text, Text3.Text, Text4.Text, Text5.Text) 'hapus data Private Sub Command3_Click() If Not (rs.eof Or rs.bof) Then rs.delete Else
MsgBox "data tidak ada" Form Penghitung Obat Private Sub Command1_Click() Dim a, b, c As Integer a = Val(Text1.Text) b = Val(Text2.Text) c = Val(Text3.Text) Text4.Text = (a * b) - (a * b * c) / 100 Private Sub Command2_Click() frmtransaksipenjualan.show frmpenghitungobat.hide Private Sub Command3_Click() Text1 = " " Text2 = " " Text3 = " " Text4 = " " Text5 = " " Text5.SetFocus