Hi all,

I'm trying to get two columns in a DataGridView to talk to each other.

One of the columns contains countries. The other contains locales
(states, provinces, territories, etc.). Both of these columns are set
up as DataGridViewComboBoxColumns.

I want it to work so that, if the user selects a country, the locale
combo box in the adjacent cell will be auto-filtered to show only
locales for the selected country. Similarly, if the user selects a
locale first, the appropriate country should be auto-selected.

Is this possible? If so, how should it be done?

I thought maybe I could add a WHERE clause to the Locale SELECT query,
but I couldn't figure out how to test it against the value of the
neighboring cell (tried to create a @Country parameter but got
nowhere). Also not sure if the combo boxes in a single column can even
have unique filters.

Another thought was that I may need to write event handlers for the
combo boxes that apply filters. But this still requires that you can
have unique filters for the combo boxes in a column.

Any help on this much appreciated.

Thanks,

-Dan