Discussion Locked

Search feature in Access form

0 helpful
2 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
How can I add a search features on Access forms. Lets say the user wants to find a record by entering first or last name or any other field to find a record either on the current or a different table. How can I do this?

2 replies

by john.a.wills

Here is one way:
Private Sub SeekByID_AfterUpdate()
Dim rs As Object
Me.Filter = ""
Set rs = Me.Recordset.Clone
rs.findfirst "[ID]=" & Str(Me.SeekByID)
Me.Bookmark = rs.Bookmark
End Sub

by coire.reilly

Can you dumb this down a little? I'm new to working with Access. Does this go in a text box? If so then where should I place this code?

Thanks for your help!

This discussion is closed to new replies.