"Linked" List Boxes in Form

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

I have a list of sales rep names in one list box that I'd like to have
associated with multiple records of their sales in a second list box on a
form. Essentially, when a user clicks on a name on the left list box, the
right list box displays all the sales in the database under that name in a
one-to-many type relationship. I'm having a little trouble figuring out the
right approach for this. Should I add code to the left list box to query, or
is it better to use a sub-form here?

Thanks!
 
In the first listbox's AfterUpdate or Click event (either should work),
modify the second listbox's RowSource based on the selection in the first
listbox. That's always worked for me.

Carl Rapson
 
Thanks, Carl, that indeed worked perfectly!

Carl Rapson said:
In the first listbox's AfterUpdate or Click event (either should work),
modify the second listbox's RowSource based on the selection in the first
listbox. That's always worked for me.

Carl Rapson
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top