Beispiel #1
0
        private void pictureBox1_Click(object sender, EventArgs e)
        {
            this.Hide();
            interfaceMain main_i = new interfaceMain(ldb);

            main_i.Show();
        }
Beispiel #2
0
        private void buttonReturn_Click(object sender, EventArgs e)
        {
            this.Hide();
            interfaceMain main_i = new interfaceMain(ldb);

            main_i.Show();
        }
        private void signin()
        {
            LibraryDB lb    = new LibraryDB("SQL Server", "sa", "sa");
            var       state = lb.Login(boxID.Text, boxpassword.Text);

            switch (state)
            {
            case LibraryDB.LoginStatus.Wrong:
                MessageBox.Show("Wrong password. Try again or click Forgot password to reset it.");
                break;

            case LibraryDB.LoginStatus.NotExist:
                MessageBox.Show("Couldn't find your account ID.");
                break;

            case LibraryDB.LoginStatus.Success:
                this.Hide();
                interfaceMain main_i = new interfaceMain(lb);
                main_i.Show();
                break;
            }
        }