
Command to Close and Reopen Sub Form
Quote:
> I'm using a VB Command to change the SQL statement on my Query
> qry_SEARCH
> On the main form, frm_SEARCH, I have a sub form sfrm_SEARCH bound to
> this Query
> I tried using Me![sfrm_SEARCH].Requery to refresh the data, but that
> did not work.
Then try directly requery the forms reocrdset, so, try
me![sfrm_Search].Form.Requery
If the above don't work, then something else seriously is wrong.
Quote:
> Could i use to close and reopen the Sub Form?
No, and in fact, a sub-form does not open,and close in a sense. Remember
text box controls, or any control (including a sub-form control) is a just a
control on the form. You can set what field a text box points to, and in the
case of a sub-form control, you can set what sub-form that control actually
uses. And, you can have multiple copes of the SAME sub-form on a screen, but
of course the sub-form control would have to have a different name.
--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
http://www.members.shaw.ca/AlbertKallal