cmb

  if (this.cmbMonitorLevelPollutionSource.Items.Count == 0)
            {
                this.cmbMonitorLevelPollutionSource.Items.Add(new ComboBoxItem() { Content = "国控", Tag = "00" });
                this.cmbMonitorLevelPollutionSource.Items.Add(new ComboBoxItem() { Content = "省控", Tag = "01" });
                this.cmbMonitorLevelPollutionSource.Items.Add(new ComboBoxItem() { Content = "市控", Tag = "02" });
            }

  ComboBoxItem cmbItem = cmbMonitorLevelPollutionSource.SelectedItem as ComboBoxItem;
            pollutionsourceContion.MonitorLevel = cmbItem.Tag.ToString().Trim();

你可能感兴趣的:(c)