예제 #1
0
        private void buttonBack_Click(object sender, EventArgs e)
        {
            var form = new FormCena(vidsporta, rayon);

            form.Show();
            this.Hide();
        }
예제 #2
0
        private void buttonOk_Click(object sender, EventArgs e)
        {
            if (!Check())
            {
                MessageBox.Show("Выберите хотя бы один пункт", "Ошибка", MessageBoxButtons.OK,
                                MessageBoxIcon.Error);
                return;
            }
            List <string> rayon = new List <string>();

            foreach (Control c in this.Controls)
            {
                if (c is CheckBox && (c as CheckBox).Checked)
                {
                    rayon.Add(c.Text);
                }
            }
            var form = new FormCena(vidsporta, rayon);

            form.Show();
            this.Hide();
        }