private void disableComboBox(SelectionPreservingComboBox comboBox, string text) { comboBox.DroppedDown = false; comboBox.SelectedIndex = -1; comboBox.Items.Clear(); comboBox.Enabled = false; comboBox.DropDownStyle = ComboBoxStyle.DropDown; comboBox.Text = text; }
private void enableComboBox(SelectionPreservingComboBox comboBox) { comboBox.Enabled = true; comboBox.DropDownStyle = ComboBoxStyle.DropDownList; }