示例#1
0
        private void verifyAccount_Click(object sender, EventArgs e)
        {
            //check if username and password inputted matches
            if (usernameInput.Text == Form1.user && passwordInput.Text == Form1.pass)
            {
                //if matches, move to next screen and remove old form
                Form f = this.FindForm();
                f.Controls.Remove(this);

                VerificationScreen vs = new VerificationScreen();
                f.Controls.Add(vs);
            }
            else
            {
                //if username didn't match up, send error message
                wrongInput.Text = "The information you have inputted is incorrect. Please check your username and password.";
            }
        }
示例#2
0
        private void verifyAccount_Click(object sender, EventArgs e)
        {
            //check if username and password inputted matches
            if (usernameInput.Text == Form1.user && passwordInput.Text == Form1.pass)
            {
                //if matches, move to next screen and remove old form
                Form f = this.FindForm();
                f.Controls.Remove(this);

                VerificationScreen vs = new VerificationScreen();
                f.Controls.Add(vs);
            }
            else
            {
                //if username didn't match up, send error message
                wrongInput.Text = "The information you have inputted is incorrect. Please check your username and password.";
            }
        }