Hi all
Ive got a form with combo which filters a recordset using an sql statement,
and it works fine, here's the code.
mySql = "SELECT *from qryAllByArea WHERE tblInspections. Area= " & Chr(34) &
Me.cboAreaFilte r & Chr(34) & " ORDER BY qryAllByArea.Nc rId;"
Me.RecordSource = mySql
Me.cboNCRId.Row Source = mySql 'Im using this cbo to find records in the
Filtered set. .
Me.Requery
This works fine for me from the form.
I have dropped this form as a subform onto an unbound MainForm, (tabbed
menu) and I'm not getting the same results.
I'm not getting any error message, just not the same number of records being
returned. Funny thing is the cboNCRId has the full set,
but the subform does not display them!
Have tried it in a new form and it works.
Is there any property of the parent form or the tab control which might
restrict the number of records on the subform. ???
Have sorted it by copying the combo into a new form, and the form code.
Works fine like this. Will delete the problem form,
but would like to track down a cause.
Thanks in advance.
BTW its Access 97SR2
Gerry Abbott.
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.518 / Virus Database: 316 - Release Date: 11/09/03