private void button1_Click(object sender, EventArgs e) { if (this.comboDensity.SelectedItem == null || this.comboSonic.SelectedItem == null || this.BRname == null) { PetrelLogger.ErrorBox("INVALID INPUT"); } else { if (this.comboDensity.SelectedItem.ToString() == this.comboSonic.SelectedItem.ToString()) { PetrelLogger.ErrorBox("WRONG INPUT"); return; } WellLog densityLog = null; WellLog sonicLog = null; if (this.mainCombo.SelectedIndex == 0 || this.mainCombo.SelectedIndex == 1) { if (this.comboDensity.SelectedItem == null || this.comboSonic.SelectedItem == null) { PetrelLogger.InfoOutputWindow("!!Process Terminated. Log Missing!!"); } else { foreach (WellLog log in wlog) { if (this.comboDensity.SelectedItem.ToString() == log.Name) { densityLog = log; } else if (this.comboSonic.SelectedItem.ToString() == log.Name) { sonicLog = log; } } } if (!(densityLog == null || sonicLog == null)) { PetrelLogger.InfoOutputWindow("!!Iteration started!!"); RACO obj1 = new RACO(densityLog, sonicLog); obj1.rhoC = Convert.ToInt32(this.densityClayText.Text); obj1.rhoQ = Convert.ToInt32(this.densityQuartzText.Text); obj1.rhoW = Convert.ToInt32(this.densityWaterText.Text); obj1.rhoO = Convert.ToInt32(this.densityOilText.Text); obj1.Kc = Convert.ToInt64(this.bulkClayText.Text) * 1000000; obj1.Kq = Convert.ToInt64(this.bulkQuartzText.Text) * 1000000; obj1.Kw = Convert.ToInt64(this.bulkWaterText.Text) * 1000000; obj1.Ko = Convert.ToInt64(this.bulkOilText.Text) * 1000000; obj1.Gc = Convert.ToInt64(this.shearClayText.Text) * 1000000; obj1.Gq = Convert.ToInt64(this.shearQuartzText.Text) * 1000000; obj1.RPMndex = this.comboRPM.SelectedIndex; obj1.porLog = this.porText.Text; obj1.clayLog = this.claycontText.Text; obj1.waterLog = this.waterSatText.Text; obj1.minPor = Convert.ToDouble(this.minPorText.Text); obj1.maxPor = Convert.ToDouble(this.maxPorText.Text); obj1.minWater = Convert.ToDouble(this.minWaterText.Text); obj1.maxWater = Convert.ToDouble(this.maxWaterText.Text); obj1.minClay = Convert.ToDouble(this.minClayText.Text); obj1.maxClay = Convert.ToDouble(this.maxClayText.Text); obj1.maincomboIndex = this.mainCombo.SelectedIndex; obj1.b1 = BR; obj1.workingFunction(); PetrelLogger.InfoOutputWindow("Process Completed"); } } } }
private void button1_Click(object sender, EventArgs e) { if (this.comboDensity.SelectedItem == null || this.comboSonic.SelectedItem == null || this.BRname==null) PetrelLogger.ErrorBox("INVALID INPUT"); else { if (this.comboDensity.SelectedItem.ToString() == this.comboSonic.SelectedItem.ToString()) { PetrelLogger.ErrorBox("WRONG INPUT"); return; } WellLog densityLog = null; WellLog sonicLog = null; if (this.mainCombo.SelectedIndex == 0 || this.mainCombo.SelectedIndex == 1) { if (this.comboDensity.SelectedItem == null || this.comboSonic.SelectedItem == null) { PetrelLogger.InfoOutputWindow("!!Process Terminated. Log Missing!!"); } else { foreach (WellLog log in wlog) { if (this.comboDensity.SelectedItem.ToString() == log.Name) densityLog = log; else if (this.comboSonic.SelectedItem.ToString() == log.Name) sonicLog = log; } } if (!(densityLog == null || sonicLog == null)) { PetrelLogger.InfoOutputWindow("!!Iteration started!!"); RACO obj1 = new RACO(densityLog, sonicLog); obj1.rhoC = Convert.ToInt32(this.densityClayText.Text); obj1.rhoQ = Convert.ToInt32(this.densityQuartzText.Text); obj1.rhoW = Convert.ToInt32(this.densityWaterText.Text); obj1.rhoO = Convert.ToInt32(this.densityOilText.Text); obj1.Kc = Convert.ToInt64(this.bulkClayText.Text) * 1000000; obj1.Kq = Convert.ToInt64(this.bulkQuartzText.Text) * 1000000; obj1.Kw = Convert.ToInt64(this.bulkWaterText.Text) * 1000000; obj1.Ko = Convert.ToInt64(this.bulkOilText.Text) * 1000000; obj1.Gc = Convert.ToInt64(this.shearClayText.Text) * 1000000; obj1.Gq = Convert.ToInt64(this.shearQuartzText.Text) * 1000000; obj1.RPMndex = this.comboRPM.SelectedIndex; obj1.porLog = this.porText.Text; obj1.clayLog = this.claycontText.Text; obj1.waterLog = this.waterSatText.Text; obj1.minPor = Convert.ToDouble(this.minPorText.Text); obj1.maxPor = Convert.ToDouble(this.maxPorText.Text); obj1.minWater = Convert.ToDouble(this.minWaterText.Text); obj1.maxWater = Convert.ToDouble(this.maxWaterText.Text); obj1.minClay = Convert.ToDouble(this.minClayText.Text); obj1.maxClay = Convert.ToDouble(this.maxClayText.Text); obj1.maincomboIndex = this.mainCombo.SelectedIndex; obj1.b1 = BR; obj1.workingFunction(); PetrelLogger.InfoOutputWindow("Process Completed"); } } } }