cboBox requery and = original value

C

Chris

Hello all, I have a combo box that is based on a table that displays the
names of banks. If the user enters a bank name that is not in the list, the
notInList informs the user to double click on the combobox to add the bank.
Using the double click event, a form will appear for bank details with the
bank name being automatically filled in on the form.

On the form Close event I have the combobox requeried so it will have the
new bankname in it's list

I would like to add some code that would set the combobox to the original
value

I.e. user enters Hlifax into cbobox -> Double clicks ->Form opens -> User
enters Extra bank details -> form closes -> previous form is shown with
Halifax in the cboBox.

Please help
 
G

Guest

hi,
If your combo box record sorce is a table, then the bank
must be added to that table. then, after adding the new
bank to the table, when you requery the combo box, the new
bank will be there.
so you will have to add code to your popup form that adds
the new bank to the table.
 
D

david epsom dot com dot au

Forms("OriginalForm").cboBox.requery
Forms("OriginalForm").cboBox = "NewValue"

(david)
 

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

Top