Update a Combo Box when a record is added

  • Thread starter Thread starter Alison
  • Start date Start date
A

Alison

I have a combo box on a form that allows my users to
choose a client. Many times the client is not in the
supporting table. I would like an easy way for the user
to add the new record to the client table and see the
client in the combo box on main form. If I need to use
VBA, I'm ok with that.

Thanks so much for your responses,
Alison
 
I think this is what you are looking for.

Assuming table name is "Support" and field name is "Client"

1) Go to the properties of the combobox under "Data" tab
2) Set the Row Source Type = table/query
3) set the Row Source =

SELECT DISTINCT [Support].[Client] FROM Support;

4) Done

User can enter new Client Name in the combobox and save
the record. The next time the user want to enter the same
name, it will show up in the combobox.
 
Thanks, this is exactly what I'm looking to do. I also
need to add additional information.

To open the popup form, I need to create a procedure to
do this, correct? If yes, I can do that.

Regarding requery on the combo box control, I've had
problems in the past getting this to work. What event
should the requery procedure be placed in? What would
the VBA look like.

Thanks so much for your help!!
Alison
 
Back
Top