Listbox_Click problem

Milothicus

Registered User.
Local time
Today, 09:49
Joined
Sep 24, 2004
Messages
134
i've attached a small database (not all parts work, but the relevant ones do) showing a client/contact selection system. the listbox shows results of the search from the fields at the top. if you click on the second or third contact for a client, it brings up the client properly, but for some reason doesn't update the subform, so it always shows the first contact for the client.

is it possible to get the subform to show the contact clicked on, instead of the first contact for the client clicked on?

dummy data:
1-1 is first client, first contact
1-2 is first client, second contact etc.
 

Attachments

Have you linked the Child/Master fields between the two forms?
 
yeah, they're linked on clientID.

also, the listbox is bound to contactID, so i would think it would select the contact, but it only selects the client.

table info:

Contact_Info:
contactID (PK)
ClientFK (foreign key to ClientID)
ContactName, etc.

Client Info:
ClientID (PK)
ClientName, etc.

the subform only shows the contacts for the current client, but always selects the first, not the one clicked on.

one more oddity:

because there are 3 (in the example) contacts for client 1, client 1 shows up 3 times in the listbox.

the query for the listbox is also the recordsource for the form.

when you click 'next client' or 'previous client', there are seemingly 3 'client 1''s, and which one it starts on IS determined by which you click on in the listbox.
 

Users who are viewing this thread

Back
Top Bottom