private void comboState_SelectedIndexChanged(object sender, EventArgs e) { _selectedState = MessageRegions.States.FirstOrDefault(x => x.Name == comboState.Text); if (_selectedState != null) { comboCounty.Items.Clear(); comboCounty.Text = ""; _selectedCounty = null; foreach ( var thisCounty in MessageRegions.Counties.Where(x => x.state.Id == _selectedState.Id).OrderBy(x => x.Name)) { comboCounty.Items.Add(thisCounty.Name); } } }
public SAMERegion(SAMEState state, SAMECounty county) { State = state; County = county; }