Find Record Problem

indesisiv

Access - What's that?
Local time
Today, 06:45
Joined
Jun 13, 2002
Messages
265
find record problem

I am using a simple search to goto specific records but.

Dim rs As Object
Set rs = Me.RecordsetClone
rs.FindFirst "[IDCode] = " & "'" & strPersonIDSelect & "'"
Me.Bookmark = rs.Bookmark


I have a couple of records with a " ' " in them and it appears to break up the string.

So this just comes up with an error - missing operator and highlights the findfirst line.

Is there a way to work around this. I have to search on this field!!!

Anyhelp will be greatfully received.

Steve
 
Re: find record problem

Code:
        Dim rs As DAO.Recoset
        Set rs = Me.RecordsetClone
        rs.FindFirst "[IDCode] = """ & strPersonIDSelect & """"
        Me.Bookmark = rs.Bookmark
 
Thanks a lot mile - Works like a charm!!
:D :D
 
Even with my bad spelling of Recordset? :confused: :p
 
I didn't notice ...
I musta put it in correct when i typed it in automatically ...
Either that or i can't read properly!!
:D :confused:
 

Users who are viewing this thread

Back
Top Bottom