So I used John's guide for a name search box.
http://www.access-programmers.co.uk/forums/showthread.php?t=188663
We are using the Database and have come across an error. We have two records (two names) excatly the same. When we use the dynamic search it shows both records in the results box. BUT when I try to load the record it doesn't load them. I think it may be a problem with my Select Record button which has the following code.
I can see excatly where the issue is, as it is choosing the first record in the list with that name. when in fact I need a piece of code to choose the record "selected" on the list.
How would I go about that?
http://www.access-programmers.co.uk/forums/showthread.php?t=188663
We are using the Database and have come across an error. We have two records (two names) excatly the same. When we use the dynamic search it shows both records in the results box. BUT when I try to load the record it doesn't load them. I think it may be a problem with my Select Record button which has the following code.
Code:
Dim bkmk As Variant
Dim strField As String
Me.RecordsetClone.MoveFirst
'Find the first record that matches what
'is in the search text box.
Me.RecordsetClone.FindFirst "Name Like " _
& Chr(34) & Me.SearchResults & "*" & Chr(34)
If Me.RecordsetClone.NoMatch Then
MsgBox "No Match"
Else
bkmk = Me.RecordsetClone.Bookmark
Me.Recordset.Bookmark = bkmk
End If
I can see excatly where the issue is, as it is choosing the first record in the list with that name. when in fact I need a piece of code to choose the record "selected" on the list.
How would I go about that?