Re-Quarrying a combo box in a sub form

  • Thread starter Thread starter Gary Hull
  • Start date Start date
G

Gary Hull

Here is the problem

I have a form with a sub-form

On the main form I have a button that opens another form to enter material
types.

Then on the sub-form there is a combo box where I can select the material
type.

I am having problems re-quarrying the combo box on the sub form, to get the
new material type to show up I have to close the form and restart it.
 
Where are you trying to run the requery from?

If it's in the subform, it should simply be Me!MyComboBox.Requery

If it's in the main form, it should be something like
Me!MySubform.Form!MyComboBox.Requery.

Note that MySubform above is the name of the subform control on the main
form, which may or may not be the name of the form being used as the
subform. If you created the subform by dragging the one form onto the other,
they should be the same. However, if you created the subform by adding a
subform control to the main form, then populated that control (either
manually or using the wizard), the subform control will likely be named
something like Child0.
 
Back
Top