ok the first error message that comes up is
The Microsoft Jet database engine cannot find the input tabel or query 'cd_serial_numbers_'. Make sure it exists and that its nameis spelled correctly.
The second one that comes up is
Run-time error '-2147217865 (80040e37)':
Method 'Refresh' of object 'Iadodc' failed.
My code is
Dim search As String
Dim band As String
' band = Trim(txtband.Text) <- do i need this?
search = "select * from cd_serial_numbers"
If Len(band) Then
If blnFirstWhere Then
blnFirstWhere = False
search = search & " WHERE"
Else
search = search & " OR"
End If
End If
search = search & " where (band_name = ' " & txtband.Text & " ' ) "
Debug.Print search
Adodc1.RecordSource = search
Adodc1.Refresh
What is wrong with it?




Reply With Quote