DAFTAR KODE PROGRAM KODE FORM LOGIN Private Sub cmdbaru_Click() If Me.TxtUser.Text <> "yuni" Then ' MsgBox "Nama User salah", vbCritical + vbOKOnly, "Distro 72 Madiun" Else If Me.TxtKunci.Text <> "yuni" Then MsgBox "Password Anda Salah", vbCritical + vbOKOnly, "Distro 72 Madiun" Else Unload frmLogin mdiDistro.Show End If End If End Sub Private Sub cmdubah_Click() Unload Me End Sub Private Sub Form_Load() SetFormCenter frmLogin End Sub Private Sub lbJudul_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single) If Button = vbLeftButton Then ReleaseCapture Call SendMessage(Me.hWnd, WM_NCLBUTTONDOWN, HTCAPTION, 0&) End If End Sub Private Sub TxtKunci_Change() End Sub Private Sub TxtUser_Change() End Sub KODE FORM AKUN Dim tmpJenis As String, isiLv As ListItem, Tambah As Boolean, Ganda As Boolean Dim NamaAkun As String Private Sub cbTipe_Click() Me.TxtId.Text = Me.cbTipe.ListIndex + 1 End Sub Private Sub cmdbaru_Click() Me.Frame1.Visible = True KosongText Tambah = True Me.cbTipe.SetFocus cbTipe_Click End Sub Private Sub cmdBatal_Click() If Tambah = True Then Me.TxtNoAkun.Text = "" KondisiAwal End Sub Private Sub cmdhapus_Click() If Me.TxtNoAkun.Text = "" Then MsgBox "Pilih Akun yang ingin diHapus" Else If MsgBox("Data ingin diHapus", vbQuestion + vbYesNo, "Distro 72") = vbYes Then 'hapus t_akun StrSql = "DELETE FROM akun WHERE kdakun='" & tmpJenis & "'" conn.Execute StrSql End Sub
KODE FORM PEMBELIAN Sub isiKategori() Dim rsKategori As New ADODB.Recordset With rsKategori StrSql = "SELECT * FROM kategori" .Open StrSql, conn, adOpenDynamic, adLockReadOnly cbKategori.Clear If .RecordCount > 0 Then .MoveFirst While Not .EOF Me.cbKategori.AddItem .Fields("kategori") .MoveNext Wend End If Close End With Set rsKategori = Nothing End Sub Function GetKodeBarang() As String Dim rsKodeBrg As New ADODB.Recordset Dim SqlStr As String SqlStr = "SELECT kdbrg FROM barang" With rsKodeBrg .Open SqlStr, conn, adOpenForwardOnly, adLockReadOnly .Sort = "kdbrg Asc" ' If KodeBaru = GetKodeBarang Then ' GetKodeBarang = "BRG-" & Right("0000000" & Trim(Str(Val(Right(KodeBaru, 7)) + 1)), 5) ' GetKodeBarang = Right("0000000" & Trim(Str(Val(Right(KodeBaru, 5)) + 1)), 5) ' KodeBaru = GetKodeBarang ' Else' KodeBaru = GetKodeBarang ' End If ' .Close End With Set rsKodeBrg = Nothing End Function KODE FORM PENJUALAN Sub TransaksiBaru() If NamaUser = "" Then NamaUser = "Okta" Me.dtTglJual.Value = Date Me.TxtNota.Text = GetNoJual Me.TxtKasir.Text = NamaUser Me.lbKeterangan.Caption = Trim(Me.TxtNota.Text) & "/" & Format(dtTglJual.Value, "ddMM-yy") & "/" & Format(Time, "HH:mm:ss") Me.lvJual.ListItems.Clear Me.TxtGTotal.Text = 0 Me.TxtBayar.Text = 0 Me.TxtKembali.Text = 0 Me.TxtKodeBrg.SetFocus Me.TxtKodeBrg.Locked = False Me.cmdbaru.Visible = False Me.cmdsimpan.Visible = True Me.cmdBatal.Visible = True
End Sub Function GetNoJual() As String Dim SqlStr As String, rsJual As New ADODB.Recordset SqlStr = "SELECT nota FROM penjualan WHERE month(tgl_jual)=" & Format(dtTglJual.Value, "MM") & " AND year(tgl_jual)=" & _ Format(dtTglJual.Value, "yyyy") & " GROUP BY nota" With rsJual .Open SqlStr, conn, adOpenForwardOnly, adLockReadOnly .Sort = "nota Asc" GetNoJual = "STJ." & Right(Format(dtTglJual.Value, "yyyyMMdd"), 6) & "." & Right("000" & Trim(Str(.RecordCount + 1)), 4) .Close End With Set rsJual = Nothing End Function KODE FORM NERACA Sub NeracaBaru() On Error Resume Next If Me.cbBulan.Text = "" Or Me.cbTahun.Text = "" Then Exit Sub Dim rsNeraca As New ADODB.Recordset StrSql = "SELECT * FROM neraca WHERE periode='" & Me.cbTahun.Text & Me.cbBulan.ListIndex + 1 & _ "' AND Left(kdakun, 1) = '1' ORDER BY kdakun" Me.lvAkun.ListItems.Clear With rsNeraca 'aktiva .Open StrSql, conn, adOpenDynamic, adLockReadOnly Me.TxtDebet.Text = 0 Me.TxtKredit.Text = 0 If .RecordCount > 0 Then .MoveFirst While Not .EOF Set isiLv = Me.lvAkun.ListItems.Add(Text:=.Fields("kdakun")) isiLv.SubItems(1) = .Fields("nmakun") Me.TxtDebet.Text = Me.TxtDebet.Text + Val(.Fields("saldo")) If Val(.Fields("saldo")) >= 0 Then isiLv.SubItems(2) = FormatAngka(Val(.Fields("saldo"))) Else isiLv.SubItems(2) = "(" & FormatAngka(Val(.Fields("saldo")) * -1) & ")" End If isiLv.SubItems(3) = .Fields("periode") .MoveNext Wend Set isiLv = Me.lvAkun.ListItems.Add(Text:=" ") Set isiLv = Me.lvAkun.ListItems.Add(Text:=" ") isiLv.SubItems(1) = "Total Nilai Aktiva" isiLv.SubItems(2) = FormatAngka(Me.TxtDebet.Text) Set isiLv = Me.lvAkun.ListItems.Add(Text:=" ") Set isiLv = Me.lvAkun.ListItems.Add(Text:=" ") .Close
End With Else .Close End If End With cekTotal Set rsNeraca = Nothing End Sub
KODE FORM SUPPLIER Private Sub cmdbaru_Click() Tambah = True KondisiAksi Me.TxtKode.Text = GetKodeSPL Me.TxtNama.Text = "" Me.TxtAlamat.Text = "" Me.TxtKota.Text = "" Me.TxtTelp.Text = "" Me.TxtKeterangan.Text = "" Me.TxtNama.SetFocus End Sub Function GetKodeSPL() As String Dim rsKodeSPL As New ADODB.Recordset Dim SqlStr As String SqlStr = "SELECT idspl FROM supplier ORDER BY idspl" With rsKodeSPL .Open SqlStr, conn, adOpenForwardOnly, adLockReadOnly .Sort = "idspl Asc" GetKodeSPL = "SPL-" & GetKodeSPL .Close End With Set rsKodeSPL = Nothing End Function KODE FORM KARYAWAN Dim tmpUserID As String, isiLv As ListItem, Tambah As Boolean, Ganda As Boolean Private Sub cmdbaru_Click() Me.txtUserId.Text = "" Me.txtPassword.Text = "" Me.txtNama.Text = "" 'Me.cbDivisi.Text = "" Tambah = True KondisiAksi Me.txtUserId.SetFocus End Sub
KUESIONER KELAYAKAN SISTEM DI DISTRO 72 MADIUN
Nama Unit
: Okta Widiastuti : Kasir
Berikan tanggapan anda mengenai pertanyaan berikut menurut preferensi anda :
1. Bagaimana tanggapan anda mengenai sistem informasi yang baru? Tanggapan :
2. Bagaimana dengan tampilan dan sistem pengolahan datanya, apakah sudah sesuai dengan harapan? Tanggapan :
3. Bagaimana dampak yang anda rasakan setelah adanya sistem yang baru? Tanggapan :
Saran :
KUESIONER KELAYAKAN SISTEM DI DISTRO 72 MADIUN
Nama Unit
: Hanggar Aprianti : Gudang
Berikan tanggapan anda mengenai pertanyaan berikut menurut preferensi anda :
1. Bagaimana tanggapan anda mengenai sistem informasi yang baru? Tanggapan :
2. Bagaimana dengan tampilan dan sistem pengolahan datanya, apakah sudah sesuai dengan harapan? Tanggapan :
3. Bagaimana dampak yang anda rasakan setelah adanya sistem yang baru? Tanggapan :
Saran :
KUESIONER KELAYAKAN SISTEM DI DISTRO 72 MADIUN
Nama Unit
: Andy Gromiko : Pemilik (owner)
Berikan tanggapan anda mengenai pertanyaan berikut menurut preferensi anda :
1. Bagaimana tanggapan anda mengenai sistem informasi yang baru? Tanggapan :
2. Bagaimana dengan tampilan dan sistem pengolahan datanya, apakah sudah sesuai dengan harapan? Tanggapan :
3. Bagaimana dampak yang anda rasakan setelah adanya sistem yang baru? Tanggapan :
Saran :