예제 #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            if (CheckAllEnteredValues())
            {
                if (!FarFieldRequestNameMatching(textBoxTitle.Text) || reducting)
                {
                    if (radioButtonType1.Checked)
                    {
                        parentForm.renderControl1.removingArc(templateLable);
                        DrawFarFieldArc(Title);
                    }

                    SaveCurrentParameters();

                    FarFieldRequestTemplate fft = new FarFieldRequestTemplate(this);
                    if (reducting)
                    {
                        parentForm.ChangeFarFieldRequest(parentTemplate.Lable, fft);
                    }
                    else
                    {
                        parentForm.AddFarFieldRequest(fft);
                    }
                    Close();
                }
                else
                {
                    textBoxTitle.BackColor = Color.Red;
                }
            }
        }