Hi all,
I have an unbound form that contains a combo box. This combo box has a rowsource set OnOpen:
On 1st run this works fine. However, some other controls on the form will often force the SQL of the underlying query (qry_rpt_BaseData2) to change. This is intentional. My problem is the combo box list doesn't reflect the change. I have added the following into the OnEnter event of the combo box:
but it doesn't seem to work. I know the SQL is changing OK as other combo boxes look at the updated query (as long as they haven't already been "opened").
The Requery and Dropdown events are working OK all over my db but all other combos use table rather than queries - what am I missing??!!
Thanks loads,
Jason
I have an unbound form that contains a combo box. This combo box has a rowsource set OnOpen:
Code:
Me.Combo_Suppliers.RowSource = "SELECT DISTINCT qry_rpt_BaseData2.SupplierID, qry_rpt_BaseData2.Supplier FROM qry_rpt_BaseData2 ORDER BY [Supplier]"
On 1st run this works fine. However, some other controls on the form will often force the SQL of the underlying query (qry_rpt_BaseData2) to change. This is intentional. My problem is the combo box list doesn't reflect the change. I have added the following into the OnEnter event of the combo box:
Code:
Me.Combo_Suppliers.Requery
Me.Combo_Suppliers.Dropdown
but it doesn't seem to work. I know the SQL is changing OK as other combo boxes look at the updated query (as long as they haven't already been "opened").
The Requery and Dropdown events are working OK all over my db but all other combos use table rather than queries - what am I missing??!!
Thanks loads,
Jason