Example #1
0
        private void btn_Back_Click(object sender, EventArgs e)
        {
            frm_Add_New_Employee obj = new frm_Add_New_Employee();

            obj.Show();
            this.Hide();
        }
 private void btn_Submit_Click(object sender, EventArgs e)
 {
     if (tb_Username.Text == "Admin" && tb_Password.Text == "a123")
     {
         MessageBox.Show("Login Successfull!!");
         Global_Vars.Username = "******" + tb_Username.Text;
         frm_Add_New_Employee add = new frm_Add_New_Employee();
         add.Show();
         this.Hide();
     }
     else
     {
         lbl_Note.Text      = "Enter Valid Username && Password";
         lbl_Note.ForeColor = Color.Red;
     }
     tb_Username.Clear();
     tb_Password.Clear();
     tb_Username.Focus();
     tb_Password.Enabled = false;
     btn_Submit.Enabled  = false;
 }