Using access 2000, I have a form with 2 combo boxes.
Combo1 contains group information which when selected I wish to use in a query which populates detailed data in combo2.
Combo1 is populated by a query which works ok. I have tried to use the index value from combo1 as a filter for combo2 but am unable to identify the correct way to do this. I have tried using 'applyfilter' to a docmd in vb but always get a type error (the criteria is numeric). I have tried to update the data from vb code using the change event in combo1, but cannot find an 'addnew' method or its equivalent in vba, so cannot add my values to combo2.
I have also tried to use a named query on combo2 to select the data and have included the criteria in the design mode build function (right click on criteria), but connot find a method of refreshing the query after selecting a value in combo1.
There must be a realy simple way of doing this but can anyone help or or suggest how it can be done?
Many thanks in advance.
Combo1 contains group information which when selected I wish to use in a query which populates detailed data in combo2.
Combo1 is populated by a query which works ok. I have tried to use the index value from combo1 as a filter for combo2 but am unable to identify the correct way to do this. I have tried using 'applyfilter' to a docmd in vb but always get a type error (the criteria is numeric). I have tried to update the data from vb code using the change event in combo1, but cannot find an 'addnew' method or its equivalent in vba, so cannot add my values to combo2.
I have also tried to use a named query on combo2 to select the data and have included the criteria in the design mode build function (right click on criteria), but connot find a method of refreshing the query after selecting a value in combo1.
There must be a realy simple way of doing this but can anyone help or or suggest how it can be done?
Many thanks in advance.