public XmlAddOutput CreateProgramDefine()
        {
            XmlAddOutput AddOut = new XmlAddOutput();

            AddOut.Value      = comboBox1.Text;
            AddOut.Isvariable = radioButton1.Checked;
            return(AddOut);
        }
Exemplo n.º 2
0
        public override void ControlSetup(Statement name)
        {
            XmlOutputC outputC = (XmlOutputC)name;

            for (int i = 0; i < outputC.Objects.Count; i++)
            {
                XmlAddOutput Add = outputC.Objects[i];
                if (i == 0)
                {
                    AddOutputObject us = OutputOrder[0];
                    us.radioButton1.Checked = Add.Isvariable;
                    us.radioButton2.Checked = !Add.Isvariable;
                    if (Add.Isvariable)
                    {
                        us.comboBox1.Text = Add.Value;
                    }
                    else
                    {
                        us.GetVariable();
                        us.comboBox1.SelectedItem = Add.Value;
                    }
                }
                else
                {
                    AddNumber = i;
                    AddOutputObject us = new AddOutputObject();
                    us.Name = "AddOutputObject" + AddNumber.ToString();
                    this.panel1.Controls.Add(us);
                    OutputOrder.Insert(AddNumber, us);
                    us.radioButton1.Checked = Add.Isvariable;
                    us.radioButton2.Checked = !Add.Isvariable;
                    if (Add.Isvariable)
                    {
                        us.comboBox1.Text = Add.Value;
                    }
                    else
                    {
                        us.GetVariable();
                        us.comboBox1.SelectedItem = Add.Value;
                    }
                    ObjectSorting();
                }
            }
        }