예제 #1
0
        void Start()
        {
            this.DialogResult = DialogResult.OK;
            NewsMain form2 = new NewsMain();

            form2.Show();
        }
예제 #2
0
        private void button3_Click(object sender, EventArgs e)
        {
            NewsMain form1 = new NewsMain();

            form1.Show();
            Hide();
        }
예제 #3
0
        private void button1_Click(object sender, EventArgs e)
        {
            if (tbxLogin.Text == string.Empty)
            {
                MessageBox.Show("Создайте логин");
                return;
            }

            if (tbxPasword1.Text == string.Empty || tbxPasword2.Text == string.Empty)
            {
                MessageBox.Show("Поле с паролем не заполнено");
                return;
            }
            if (tbxPasword1.Text != tbxPasword2.Text)
            {
                MessageBox.Show("Пароли не совпадают");
                return;
            }

            if (Save(tbxLogin.Text, tbxPasword1.Text) == true)
            {
                DialogResult = DialogResult.OK;
                NewsMain form1 = new NewsMain();
                form1.Show();
                //this.Close();
            }
            else
            {
                return;
            }
        }