示例#1
0
        public ScrubberCondenserValuesControl(ScrubberCondenserControl scrubberCondenserCtrl)
        {
            // This call is required by the Windows.Forms Form Designer.
            InitializeComponent();

            this.scrubberCondenserCtrl = scrubberCondenserCtrl;
            this.InitializeVariableTextBoxes(scrubberCondenserCtrl);
        }
示例#2
0
 public void InitializeVariableTextBoxes(ScrubberCondenserControl ctrl)
 {
     this.textBoxGasPressureDrop.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.GasPressureDrop);
     this.textBoxCollectionEfficiency.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.CollectionEfficiency);
     this.textBoxInletParticleLoading.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.InletParticleLoading);
     this.textBoxOutletParticleLoading.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.OutletParticleLoading);
     this.textBoxParticleCollectionRate.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.ParticleCollectionRate);
     this.textBoxMassFlowRateOfParticleLostToGasOutlet.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.MassFlowRateOfParticleLostToGasOutlet);
     this.textBoxLiquidToGasRatio.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.LiquidToGasRatio);
     this.textBoxCoolingDuty.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.CoolingDuty);
     this.textBoxLiquidRecirculationMassFlowRate.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.LiquidRecirculationMassFlowRate);
     this.textBoxLiquidRecirculationVolumeFlowRate.InitializeVariable(ctrl.Flowsheet.ApplicationPrefs, ctrl.ScrubberCondenser.LiquidRecirculationVolumeFlowRate);
 }
示例#3
0
        public ScrubberCondenserEditor(ScrubberCondenserControl scrubberCondenserCtrl)
            : base(scrubberCondenserCtrl)
        {
            //
            // Required for Windows Form Designer support
            //
            InitializeComponent();

            this.inConstruction = true;
            ScrubberCondenser scrubberCondenser = this.ScrubberCondenserCtrl.ScrubberCondenser;

            this.Text = "Scrubber Condenser: " + scrubberCondenser.Name;

            this.UpdateStreamsUI();

            this.groupBoxScrubberCondenser          = new System.Windows.Forms.GroupBox();
            this.groupBoxScrubberCondenser.Location = new System.Drawing.Point(644, 24);
            //this.groupBoxScrubberCondenser.Location = new System.Drawing.Point(1010, 24);
            this.groupBoxScrubberCondenser.Name     = "groupBoxScrubberCondenser";
            this.groupBoxScrubberCondenser.Text     = "Scrubber Condenser";
            this.groupBoxScrubberCondenser.Size     = new System.Drawing.Size(280, 240);
            this.groupBoxScrubberCondenser.TabIndex = 127;
            this.groupBoxScrubberCondenser.TabStop  = false;
            this.panel.Controls.Add(this.groupBoxScrubberCondenser);

            this.groupBoxLiquidOutlet.Size = new System.Drawing.Size(280, 300);
            //this.panel.Size = new System.Drawing.Size(1010, 329);
            //this.ClientSize = new System.Drawing.Size(1010, 351);
            //   this.panel.Size = new System.Drawing.Size(1292, 329);
            //   this.ClientSize = new System.Drawing.Size(1292, 351);

            ProcessVarLabelsControl scrubberCondenserLabelsCtrl = new ProcessVarLabelsControl(this.ScrubberCondenserCtrl.ScrubberCondenser.VarList);

            this.groupBoxScrubberCondenser.Controls.Add(scrubberCondenserLabelsCtrl);
            scrubberCondenserLabelsCtrl.Location = new Point(4, 12 + 20 + 2);

            ProcessVarValuesControl scrubberCondenserValuesCtrl = new ProcessVarValuesControl(this.ScrubberCondenserCtrl);

            this.groupBoxScrubberCondenser.Controls.Add(scrubberCondenserValuesCtrl);
            scrubberCondenserValuesCtrl.Location = new Point(196, 12 + 20 + 2);

            scrubberCondenserCtrl.ScrubberCondenser.StreamAttached += new StreamAttachedEventHandler(ScrubberCondenser_StreamAttached);
            scrubberCondenserCtrl.ScrubberCondenser.StreamDetached += new StreamDetachedEventHandler(ScrubberCondenser_StreamDetached);

            this.menuItemRating        = new MenuItem();
            this.menuItemRating.Index  = this.menuItemReport.Index + 1;
            this.menuItemRating.Text   = "Rating";
            this.menuItemRating.Click += new EventHandler(menuItemRating_Click);
            this.mainMenu.MenuItems.Add(this.menuItemRating);

            this.labelCalculationType    = new System.Windows.Forms.Label();
            this.comboBoxCalculationType = new System.Windows.Forms.ComboBox();

            // labelCalculationType
            this.labelCalculationType.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
            this.labelCalculationType.Location    = new System.Drawing.Point(300, 0);
            this.labelCalculationType.Name        = "labelCalculationType";
            this.labelCalculationType.BackColor   = Color.DarkGray;
            this.labelCalculationType.Size        = new System.Drawing.Size(192, 20);
            this.labelCalculationType.TabIndex    = 5;
            this.labelCalculationType.Text        = "Calculation Type:";
            this.labelCalculationType.TextAlign   = System.Drawing.ContentAlignment.MiddleLeft;

            // comboBoxCalculationType
            this.comboBoxCalculationType.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
            this.comboBoxCalculationType.Items.AddRange(new object[] {
                "Balance",
                "Rating"
            });
            this.comboBoxCalculationType.Location              = new System.Drawing.Point(492, 0);
            this.comboBoxCalculationType.Name                  = "comboBoxCalculationType";
            this.comboBoxCalculationType.Size                  = new System.Drawing.Size(80, 21);
            this.comboBoxCalculationType.TabIndex              = 7;
            this.comboBoxCalculationType.SelectedIndexChanged += new EventHandler(comboBoxCalculationType_SelectedIndexChanged);

            this.panel.Controls.Add(this.labelCalculationType);
            this.panel.Controls.Add(this.comboBoxCalculationType);

            this.comboBoxCalculationType.SelectedIndex = -1;
            comboBoxCalculationType.Enabled            = false; // TODO: remove later
            this.inConstruction = false;
            this.SetCalculationType(this.ScrubberCondenserCtrl.ScrubberCondenser.CalculationType);
        }