Ejemplo n.º 1
0
        private void SignInBtn_Click(object sender, EventArgs e)
        {
            var user = new User();

            user.Login    = LoginTextBox.Text;
            user.Password = PasswordTextBox.Text;
            if (user.CheckUser())
            {
                PostsForm posts = new PostsForm();
                posts.Size          = this.Size;
                posts.StartPosition = this.StartPosition;
                this.Visible        = false;

                posts.ShowDialog();

                this.Visible = true;
            }
            else
            {
                MessageBox.Show("Incorrect login or password.");
            }
        }
Ejemplo n.º 2
0
        private void PostsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            PostsForm postsForm = new PostsForm();

            postsForm.ShowDialog();
        }