Question Locked

using combo box to populate text boxes in access form

0 helpful
2 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I have an extrememly simple table that is the basis of my main form. I want to use "Name" field in a combo box bound to that table so that when selected 5 other text boxes bound to the same table populate with entries that match the name e.g."manager", "job title" etc. I have managed to build a form of this but certain things won't work. I need to start from scratch. I'm using AfterUpdate to drive the event, if someone could provide the code I need that would be great. Thanks.

2 replies

by jck

Things to do:

- Use the Change event of the combo.
- Make your code ensure upon saving/closing the combo has a set value, or they cancel out.
- Combos either hold its own data, or hit a linked table. If it's a small table, then preload the data (all data values desired to display) into the combo box, and format the columns other than the one you want to display in the combo to zero column width.
- Then on the change of the combo setting, code the Change event to populate your text boxes on the form with the 5 other columns hidden in your combo.

Good luck.

This discussion is closed to new replies.