Hello,
I am totally new with access and I have a question about an error I get on some results.
I have a search in a list box which is working, but sometimes when I click on a result in the listbox, I get the error 3001. I know that I only get this error when two or more results from the listbox has the same foreign key. The code I used to get the results in the textboxes is:
Private Sub lstKenteken_AfterUpdate()
Dim rst As ADODB.Recordset
Set rst = Me.RecordsetClone
rst.Find "[Kenteken]= " & Me.lstKenteken.Value
Me.Bookmark = rst.Bookmark
Set rst = Nothing
End Sub
Thanks,
Alexander
I am totally new with access and I have a question about an error I get on some results.
I have a search in a list box which is working, but sometimes when I click on a result in the listbox, I get the error 3001. I know that I only get this error when two or more results from the listbox has the same foreign key. The code I used to get the results in the textboxes is:
Private Sub lstKenteken_AfterUpdate()
Dim rst As ADODB.Recordset
Set rst = Me.RecordsetClone
rst.Find "[Kenteken]= " & Me.lstKenteken.Value
Me.Bookmark = rst.Bookmark
Set rst = Nothing
End Sub
Thanks,
Alexander