Using A2K, I have 2 combo boxes on a continuous form, cboCompany and
cboDescription. After I make a selection in cboCompany, I would like to have
only descriptions from cboCompany display for selection in cboDescription.
In a query, I looked for descriptions from the form and cboCompany. This
works for the first occurrence of the continuous form, but the same
descriptions are displayed for each additional line even if a new company has
been selected on cboCompany.
How can I get this to work?
Thank,
Dan
DeltaTech - 14 Jan 2008 18:08 GMT
Hi danc09
After each selection of cboCompany you need to requery cboDecsription
In the properties box of cboDescription open the select query and enter the
criteria :-
Forms!FormName.cboCompany
In the properties box of cboCompany
select "After Update" then select "Event Proceedure"
For the "Event Proceedure code enter the following command
Me.cboDescription.requery
Have fun
DeltaTech
> Using A2K, I have 2 combo boxes on a continuous form, cboCompany and
> cboDescription. After I make a selection in cboCompany, I would like to
[quoted text clipped - 8 lines]
> Thank,
> Dan
Yanick - 14 Jan 2008 18:17 GMT
In the "after update" event of cboCompany change the "row source" of
cboDescription to match the value in cboCompany.
should look like :
me.cboDescription.rowSource = "Select [YourTableName].Description FROM
[YourTableName] WHERE [YourTableName].CompanyName = '" & me.cboCompany.Value
& "'"
Should do the tirck!

Signature
Yanick
> Using A2K, I have 2 combo boxes on a continuous form, cboCompany and
> cboDescription. After I make a selection in cboCompany, I would like to have
[quoted text clipped - 6 lines]
> Thank,
> Dan