private void SetMediaMixValues() { bool WD = (cbYesNo.Text == "Yes"); Common.setValue(tbTNReduction, MediaMix.TNRemoval(bmp.MediaMixType, bmp.MediaNPercentReduction, WD), 0); Common.setValue(tbTPReduction, MediaMix.TPRemoval(bmp.MediaMixType, bmp.MediaPPercentReduction, WD), 0); }
private void cbMixes_SelectedIndexChanged(object sender, EventArgs e) { Mix = Common.getString(cbMixes); Common.setValue(tbRate, MediaMix.GPM_SF(cbMixes.Text), 3); Common.setValue(tbN, MediaMix.TNRemoval(Mix), 1); Common.setValue(tbP, MediaMix.TPRemoval(Mix), 1); Calculate(); }
private void cbBMP_SelectedIndexChanged(object sender, EventArgs e) { Common.setValue(tbTD, GetAnnualOP(), 3); BMP bmp = currentCatchment().getBMP(Common.getString(cbBMP)); Common.setValue(tbRate, MediaMix.SorptionRate(bmp.MediaMixType), 2); //tbRate.Enabled = false; Common.setValue(tbMediaWeight, MediaMix.SaturatedWeight(bmp.MediaMixType)); //tbMediaWeight.Enabled = false; Common.setValue(tbFilterVolume, bmp.MediaVolume); GetValues(); }
private void cbMixes_SelectedIndexChanged(object sender, EventArgs e) { // getValues(); if (!MediaMix.isDefined(cbMixes.Text)) { return; } bmp.MediaMixType = cbMixes.Text; //bmp.MediaNPercentReduction = Common.getDouble(tbTNReduction); //bmp.MediaPPercentReduction = Common.getDouble(tbTPReduction); SetMediaMixValues(); }
private void frmRainGarden_Load(object sender, EventArgs e) { cbMixes.DataSource = new BindingSource(MediaMix.MediaMixes(), null); cbMixes.DisplayMember = "Key"; cbMixes.ValueMember = "Key"; cbSystemType.DataSource = new BindingSource(RainGarden.SystemTypes, null); // Add this to each object assigned to a Catchment, Implement MenuItemClickhandler InterfaceCommon.BuildCatchmentMenu(menuStrip1, MenuItemClickHandler, true); menuStrip1.Items[currentCatchmentID - 1].BackColor = System.Drawing.Color.FromKnownColor(System.Drawing.KnownColor.MenuHighlight); setValues(); this.Text += currentCatchment().TitleHeader(); }
private void setMediaValues() { if (Common.getString(cbMixes) != MediaMix.User_Defined) { tbTN.Enabled = false; Common.setValue(tbTN, MediaMix.TNRemoval(currentBMP().MediaMixType)); tbTP.Enabled = false; Common.setValue(tbTP, MediaMix.TPRemoval(currentBMP().MediaMixType)); } else { tbTN.Enabled = true; Common.setValue(tbTN, currentBMP().MediaNPercentReduction); tbTP.Enabled = true; Common.setValue(tbTP, currentBMP().MediaPPercentReduction); } }
private void getValues() { currentBMP().RetentionOrDetention = Common.getString(cbSystemType); currentBMP().MediaMixType = Common.getString(cbMixes); currentBMP().VoidFraction = Common.getDouble(tbVoidFraction); currentBMP().MediaVolume = Common.getDouble(tbMediaVolume); currentBMP().WaterAboveMedia = Common.getDouble(tbWaterAboveMedia); currentBMP().MediaAreaSF = Common.getDouble(tbMediaArea); if (currentBMP().MediaMixType != MediaMix.User_Defined) { currentBMP().MediaNPercentReduction = MediaMix.TNRemoval(currentBMP().MediaMixType); currentBMP().MediaPPercentReduction = MediaMix.TPRemoval(currentBMP().MediaMixType); } else { currentBMP().MediaNPercentReduction = Common.getDouble(tbTN); currentBMP().MediaPPercentReduction = Common.getDouble(tbTP); } }
private void frmMediaMix_Load(object sender, EventArgs e) { MediaMix.PopulateComboBox(cbMixes); toolTip1.SetToolTip(cbMixes, MediaMix.ToString()); setValues(); }
private void frmMediaFilterArea_Load(object sender, EventArgs e) { SetCatchments(); MediaMix.PopulateComboBox(cbMixes); }