I have a subform that, on default, gets its data from a query. When a
button on the main form is clicked, the record source for the subform query
is changed.
My onclick code is Forms![main]![sub].Form.RecordSource = "query2"
The problem is that the subform shows no records (even though there
definitely are some that meet the query criteria). I think I need to
refresh, repaint, or requery either the subfrom or the main form, but I've
tried every combination of those steps that I can think of and the subform
stays empty. Any ideas?
bob bob - 14 Feb 2005 11:57 GMT
I should mention that the subform is a continuous form. Also, each of the
two queries being selected by the button on the main form works fine if I
simply enter it by hand in the properties of the subform. It's only when I
have the recordset change following onclick of a button on the main form
that the subform goes blank.