コード例 #1
0
        private void btnBack_Click(object sender, EventArgs e)
        {
            AdminHome adHome = new AdminHome();

            adHome.Show();
            this.Hide();
        }
コード例 #2
0
        private void btnAdminLogin_Click(object sender, EventArgs e)
        {
            string adName, Adpass;

            adName = txtAdname.Text;
            Adpass = txtAdPassword.Text;

            if (adName == "lmonyela" && Adpass == "admin1234")
            {
                ActiveForm.Hide();
                AdminHome AdHome = new AdminHome();
                AdHome.Show();
            }
            else
            {
                MessageBox.Show("Incorrect details entered. Try again", "Jiba's Movie Rental", MessageBoxButtons.RetryCancel, MessageBoxIcon.Error);
            }
        }