Mencari Rekord Dengan InputBox
Tabel yang dipakai adl Tabel Supervisor Function CariSVisor() ' adl Fungsi Pencarian data On Error GoTo Handl Dim RsSVisorView As New ADODB.Recordset Dim MySQL, NOIS, UserMsg, TXt As String UserMsg = InputBox("Masukkan NIK Yang Dicari!", " Lab~Q 5", NOIS, 5000, 3500) If StrPtr(UserMsg) 0 Then ' Start of Usermessage NOIS = UserMsg MySQL = "SELECT From Tab_Karyawan " & _ "WHERE NIK LIKE '%" & UserMsg & "%' And Tab_Karyawan.Jabatan Not Like 'Teknisi' And Tab_Karyawan.Jabatan Not Like 'Petugas' ORDER BY Tab_Karyawan.Nama" RsSVisorView.Open MySQL, DbAcax, adOpenKeyset, adLockOptimistic If RsSVisorView.BOF = True And RsSVisorView.EOF = True Then ' cari NAMA Set RsSVisorView = Nothing MySQL = "SELECT * From Tab_Karyawan " & _ "WHERE Nama LIKE '%" & UserMsg & "%' And Tab_Karyawan.Jabatan Not Like 'Teknisi' And Tab_Karyawan.Jabatan Not Like ...