tverney Posted April 25, 2005 Posted April 25, 2005 I have 1 dataset with two tables. One table is a list of states, the second table is a list of counties for each state. The goal is to have two comboboxes. The first combobox contains a list of states bound to the first table. The second combobox contains a list of counties driven by which state was selected in the first combobox. Through code I can: create and populate the dataset create a relationship between the tables bind the state table to the cmbState combobx bind the counties table to the cmbCounty combbox Through code I can't: establish the relationship between the comboboxes. I get a complete list of states in the first combobox and a complete list of counties in the second combobox, not a list of counties for the selected states. This is driving me nuts. I can do this through the use of the wizards; creating a connector, DataAdapters, dataset, a relationship, and set the appropriate datasource and the displaymember for the comboboxes but I can't seem to be able to bind the two comboboxes through code. Help is appreciated. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.