G
G deady via AccessMonster.com
I have 2 cascading combo boxes. Thr first calls all 50 states in the US.(I am
using States as the parent combo box instead of Zipcodes as many do because I
need to break down my zipcodes into maneable numbers. There are 47,000 of
them) The Second is "Supposed" to called the call all the cites and zipcodes
for the state selected. I have a problem with my WHERE clause. Without the
WHERE Clause Combo2 works fine. It shows every record in the table. When I
add the WHERE Clause It won't run. I am asked for a parameters for each field
in the second combobox.
Table1 has 2 fields-StAbb(PK) and State. Table2 has 5 fields-ZipID,ZipCode,
City, & StAbb(FK).
I have a query for each table that the combo boxes run off.
The rowsource for combo1 is
"SELECT tbl_states.StAbb, tbl_states.State FROM tbl_states ORDER BY
tbl_states.StAbb;"
The rowsource for Combo2 is:
"SELECT qry_zipcodes.ZipID, qry_zipcodes.City, qry_zipcodes.ZipCode,
qry_zipcodes.StID FROM qry_zipcodes WHERE qry_zipcodes.StAbb=Forms!
frm_clirntinformation!combo24 ORDER BY [City], [ZipCode];
It doesn't matter whether I run them off the querys or directly off the
underlying tables. The same thing happens. Can anyone tell me what I am doing
wrong?
using States as the parent combo box instead of Zipcodes as many do because I
need to break down my zipcodes into maneable numbers. There are 47,000 of
them) The Second is "Supposed" to called the call all the cites and zipcodes
for the state selected. I have a problem with my WHERE clause. Without the
WHERE Clause Combo2 works fine. It shows every record in the table. When I
add the WHERE Clause It won't run. I am asked for a parameters for each field
in the second combobox.
Table1 has 2 fields-StAbb(PK) and State. Table2 has 5 fields-ZipID,ZipCode,
City, & StAbb(FK).
I have a query for each table that the combo boxes run off.
The rowsource for combo1 is
"SELECT tbl_states.StAbb, tbl_states.State FROM tbl_states ORDER BY
tbl_states.StAbb;"
The rowsource for Combo2 is:
"SELECT qry_zipcodes.ZipID, qry_zipcodes.City, qry_zipcodes.ZipCode,
qry_zipcodes.StID FROM qry_zipcodes WHERE qry_zipcodes.StAbb=Forms!
frm_clirntinformation!combo24 ORDER BY [City], [ZipCode];
It doesn't matter whether I run them off the querys or directly off the
underlying tables. The same thing happens. Can anyone tell me what I am doing
wrong?