OzzieTheOwl
Technical User
Hi
I have the following code, which is supposed to find and navigate to a record on a form, from an entry made in a textbox in the form. The field searched could either be a number or text entry, so I have made the field a text field.
I am using Access 97 if that makes any difference.
When the code runs I am getting the following error message.
Run-time error 3464
Data type mismatch in criteria expression
When I hit Debug the following line is highlighted
rs.FindFirst "[Invoice_Number] = " & Str(Me![txtFindInvoice])
Am I missing something?
Thanks in advance for your help
Barney
I have the following code, which is supposed to find and navigate to a record on a form, from an entry made in a textbox in the form. The field searched could either be a number or text entry, so I have made the field a text field.
I am using Access 97 if that makes any difference.
Code:
Private Sub cmdFind_Click()
Dim rs As Object
Set rs = Me.RecordsetClone
rs.FindFirst "[Invoice_Number] = " & Str(Me![txtFindInvoice])
Me.Bookmark = rs.Bookmark
End Sub
When the code runs I am getting the following error message.
Run-time error 3464
Data type mismatch in criteria expression
When I hit Debug the following line is highlighted
rs.FindFirst "[Invoice_Number] = " & Str(Me![txtFindInvoice])
Am I missing something?
Thanks in advance for your help
Barney