Auto Refresh

  • Thread starter Thread starter weircolin
  • Start date Start date
W

weircolin

Hi there

I have a form and a sub form. The main form is used to add an event
to a table and the subform has a combo box that allows the user to
select and event from the table.

When I enter a new event into the form, it doesn't show in the subform
until I close it and then open it again. Is there anyway I can get it
to do this automatically, save button or something?

Cheers

Colin
 
You need to add code to refresh the combobox on the subform. If you place the
following code (replacing YourSubformName and ComboboxName with the
appropriate names) in the AfterUpdate event of the control on your form, it
should work:

Forms!YourSubformName.ComboboxName.Requery

If requery doesn't work, try refresh.
 
Happy to help.

By the way, Allan is way better at this stuff than I am. He has taught me
much of what I know. His way may provide you with a better result in the long
run.
 
Back
Top