This is how I set up the database:
tblCompanyInfo
fldCompanyID autonumber
fldCompanyName text
fldAddress text
fldState text - lookup to tblStates
fldZipCodes number
tblStates
fldStatesID autonumber
fldStates text
tblZipCodes
fldZipCodesID autonumber
fldZipCodes number
fldStateID number
tblStates has a one-to-many relationship with tblZipCodes
tblCompanyInfo.fldStates is a combobox that looks up a list of states from tblStates
I would like to create a form that fills in tblCompanyInfo, but when I get to the state field, I want to pick the state I want from a drop down box. After I pick my state, I want to click in the drop down box under ZipCode and only see ZipCodes for the state that I selected. If I choose a different state, I want to ZipCodes to update.
The update part is done in VisualBasic. Is it done under the General section or under the combobox for the ZipCode or somewhere else? The SQL statement, is that done as a query and then the combobox of the ZipCode points to that query or can you write the SQL statement somewhere else?
I appreciate any help and any suggestions regarding this database.
tblCompanyInfo
fldCompanyID autonumber
fldCompanyName text
fldAddress text
fldState text - lookup to tblStates
fldZipCodes number
tblStates
fldStatesID autonumber
fldStates text
tblZipCodes
fldZipCodesID autonumber
fldZipCodes number
fldStateID number
tblStates has a one-to-many relationship with tblZipCodes
tblCompanyInfo.fldStates is a combobox that looks up a list of states from tblStates
I would like to create a form that fills in tblCompanyInfo, but when I get to the state field, I want to pick the state I want from a drop down box. After I pick my state, I want to click in the drop down box under ZipCode and only see ZipCodes for the state that I selected. If I choose a different state, I want to ZipCodes to update.
The update part is done in VisualBasic. Is it done under the General section or under the combobox for the ZipCode or somewhere else? The SQL statement, is that done as a query and then the combobox of the ZipCode points to that query or can you write the SQL statement somewhere else?
I appreciate any help and any suggestions regarding this database.