Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Shaun E on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Combo box not working sometimes??

Status
Not open for further replies.

CatahoulaHound

Technical User
Feb 26, 2001
47
US
I have a combo box, on a form in Access 97, tied to a query that does a lookup and populates the fields accordingly. Sometimes when I select a new name, the fields will not update with new info. The info from the last name is still shown in the fields. I have to close and reopen the form to get it working again. Any thoughts anybody. All help, as always, is greatly appreciated.
Pat
 
What do you have happening when your combo box is updated? Do you have code in the "after update" property of the combo box that's supposed to be updating the values of other controls of the forms?

A little more explanation might be helpful.

You say, "Sometimes when I select a new name, the fields will not update with the new info." I assume you mean when you select a new name from the combo box some fields on the form aren't updating. But since the combo box only automatically updates the combo box field itself, you shouldn't expect it to update other fields unless they're tied somehow to the combo box field, or you have code that does stuff after the combo box update. How exactly is your form set up?

If other fields are referencing the combo box field, you might try putting the following line of code in the "after update" event of the combo box:

me.requery

That would cause the values of the textboxes referencing the combo box to be updated.

-- Herb
 
How do I add a field at runtime to an existing table within Access 2000 ? (The table name will vary, as regular imports are to be made by the user from Excel using a Macro)

Cheers, Nicko.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top