G
Guest
I have a name in a dropdown list that opens a data entry form for the person
with that name. When the name has an apostrophe in it, clicking on the name
results in an error message: when I click the debug button I get the
following code with this line (rs.FindFirst "[Expr1] = '" & Me![Combo128] &
"'") in yellow. How can I repair this code?
Option Compare Database
Private Sub Combo128_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[Expr1] = '" & Me![Combo128] & "'"
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Thanks
with that name. When the name has an apostrophe in it, clicking on the name
results in an error message: when I click the debug button I get the
following code with this line (rs.FindFirst "[Expr1] = '" & Me![Combo128] &
"'") in yellow. How can I repair this code?
Option Compare Database
Private Sub Combo128_AfterUpdate()
' Find the record that matches the control.
Dim rs As Object
Set rs = Me.Recordset.Clone
rs.FindFirst "[Expr1] = '" & Me![Combo128] & "'"
If Not rs.EOF Then Me.Bookmark = rs.Bookmark
End Sub
Thanks