Untuk membuat modul pada program Visual Basic 6.0 lakukan dengan perintah berikut :
Click menu Project pilih Add Module, lalu tekan ENTER.
Berikut merupakan modul dari sistem informasi penjualan buku :
Function Found(cData As Data, cIndex As String, ctext As String, Status As Byte) As Boolean Found = False
If cData.Recordset.RecordCount <> 0 Then cData.Recordset.MoveFirst
cData.Recordset.Index = cIndex
cData.Recordset.Seek "=", ctext
If Not cData.Recordset.NoMatch Then
Found = True
Else
If Status <> 1 Then MsgBox "Record ini tidak terdaftar !!!", , "Record"
End If
End Function
Sub Pindah(KeyAscii As Integer) If KeyAscii = 13 Then
KeyAscii = 0
SendKeys "{Tab}"
End If
End Sub
Function GotoNm(cData As Data, cIndex As String, ctext As String) As Boolean cData.Recordset.Index = cIndex
cData.Recordset.Seek "<=", ctext & "zzz"
If Not cData.Recordset.NoMatch Then
If Len(Trim(ctext)) >= 30 Then
Beep
End If
End If
End Function
Function GotoKd(cData As Data, cIndex As String, ctext As String) As Boolean cData.Recordset.Index = cIndex
cData.Recordset.Seek "<=", ctext
If cData.Recordset.NoMatch Then
If Len(Trim(ctext)) >= 5 Then
Beep
End If
End If
End Function
Subscribe to:
Post Comments (Atom)
Belum ada komentar untuk "Modul - Sistem Informasi Penjualan (VB6)"
Post a Comment
Terima kasih sudah memberikan komentar anda dengan baik.Konversi KodeEmoticonFolllow