From: Jeremey Kenney Jeremey on
I cannot seem to get my combo boxes to properly Sync up. Im not sure if the
code i am entering is wrong or what the deal is. Can someone help me out? I
have two tables State and Countydocs. I am trying to make it so when the
user uses the first combo box(cbostate) to pick a state, the counties for
that state would populate in the second combo box(cbocountydoc). Once they
pic a county I want to put a search button on there to pull up the documents
for that selected. county. I can get the cbostate box to show the states but
it will not populate the county info. can someone please help?

thanks!
From: Daryl S on
Jeremey -

In the AfterUpdate event of the first combo box, requery the second combo
box, something like this (use your form and control names):
Forms!YourFormName!CountyComboBoxName.Requery

The County combo should be set up with a row source that pulls only counties
for the state in the first combo box. This row source should look something
like this (use your form, table, field, and control names):

SELECT Counties.County, FROM Counties WHERE
(((Counties.State)=Forms!YourFormName!StateComboBoxName.value)) ORDER BY
Counties.County;

--
Daryl S


"Jeremey Kenney" wrote:

> I cannot seem to get my combo boxes to properly Sync up. Im not sure if the
> code i am entering is wrong or what the deal is. Can someone help me out? I
> have two tables State and Countydocs. I am trying to make it so when the
> user uses the first combo box(cbostate) to pick a state, the counties for
> that state would populate in the second combo box(cbocountydoc). Once they
> pic a county I want to put a search button on there to pull up the documents
> for that selected. county. I can get the cbostate box to show the states but
> it will not populate the county info. can someone please help?
>
> thanks!
 | 
Pages: 1
Prev: choose function
Next: list box requery