Listbox navigation with mouse and keyboard... (1 Viewer)

dazza61

Registered User.
Local time
Today, 03:08
Joined
Feb 7, 2006
Messages
60
Hi there,

Been struggling with this simple thing for days now...

If I move through a listbox by using the keyboard (NOT the mouse) to display the seletced record in a 'detailed' form I get the previous record that was selected in the listbox displayed in the detailed form instead of the newly selected record in the list box...

Here's the code:

Private Sub lstBook_AfterUpdate()
Dim varBkFilt As String

varBkFilt = "[BookID] = " & Me.lstBook.Column(0)
If IsLoaded("BookDetails") Then

Forms!BookDetails.Filter = varBkFilt
MsgBox varBkFilt
Forms!BookDetails.FilterOn = True
End If

End Sub

If I 'click' on the listbox the record displays fine but not if I navigate via the keyboard. Im using Access 2007.

Can anyone help?

Thanks in advance

dazza61
 

Users who are viewing this thread

Top Bottom