Subform Question

  • Thread starter Thread starter TH
  • Start date Start date
T

TH

Hi,

How do you get a combo box in a subform to show an updated list of what's in
the field? I have a person selecting a value from the combo box (of course)
and when the item they want to enter is not on the list they click a combo
button and enter the desired item on a pop form. When the person is done
entering the information, I want the subform to reflect the change (the new
item they entered). I've tried using "Requery" in a macro but it doesn't
work.

Any help would be appreciated.

Thanks

Tonye
 
Requery is the correct action to use, but how you use it depends upon when
you try to use it. And it depends somewhat on which version of ACCESS you're
using (ACCESS 2000 is less flexible than ACCESS 2002).

Please provide more info about your operation and setup.
 
I am using Access 97. I have a person selecting a value from the combo box
(of course)
and when the item they want to enter is not on the list they click a command
button and enter the desired item on a pop form. When the person is done
entering the information, I want the subform to reflect the change (the new
item they entered). I am the same person who asked about subforms on the
form list.

Thanks for your help.

Tonye
 
I've tried using "Requery" in a macro but it doesn't
work. I'm not sure what I'm doing wrong.

Tonye
 
I have not worked with A97, so I cannot speak with any certainty as to how
macros work there for requery.

I do know that A2000 allows a macro to requery a subform's recordsource, but
I've had difficulty with requerying a control on that subform unless I first
set focus to the subform control (the control that holds the subform) and
then do the requery on the control in the subform.

Is the command button on the subform? Or on the mainform?
 
The command button to enter new information is on the subform. I'll try
setting the focus to the subform control and let you know. Thanks for all
your help.

Tonye
 
If the command button is in the subform, then the focus is already on the
subform and you shouldn't need to set it there again.

How are you referencing the Requery's Control Name argument?
 
I've tried Requery with no arguments and I've tried it with the name of the
control I want to requery (without the Forms! identifier).

Tonye
 
I have it figured out. For one thing, I didn't name the combo box after I
ran the wizard to put it on the subform (duh :( ). Also, I needed to put
the name of the control without the [ ] .

Thanks.

Tonye
 
Back
Top