Exemplo n.º 1
0
 private void checkBox2_CheckedChanged(object sender, EventArgs e)
 {
     if (!UsernameBX.Equals("") && !PasswordBX.Equals(""))
     {
         if (checkBox2.Checked)
         {
             checkBox1.Checked = true;
         }
     }
 }
Exemplo n.º 2
0
 private void AddBTN_Click(object sender, EventArgs e)
 {
     UsernameBX.Clear();
     CurrentBX.Clear();
     NewBX.Clear();
     CurrentBX.Enabled      = false;
     CurrentPassPic.Visible = false;
     UsersGRDPNL.Visible    = false;
     EditUserPNL.Visible    = true;
     CloseBTN.Visible       = false;
     AdminRDBTN.Enabled     = true;
     ClerkRDBTN.Enabled     = true;
     AboutLBL.Visible       = false;
     SaveBTN.Text           = "ADD";
 }
Exemplo n.º 3
0
 private void Logins()
 {
     if (!InitData.IsBusy)
     {
         if (PasswordBX.Text.Equals(""))
         {
             PasswordTLTP.ToolTipTitle = "Password";
             PasswordTLTP.Show("Please enter your password", PasswordBX);
         }
         else if (UsernameBX.Text.Equals(""))
         {
             UsernameTLTP.ToolTipTitle = "Username";
             UsernameTLTP.Show("Please enter your username", UsernameBX);
         }
         else
         {
             if (Login.Authenticate(UsernameBX.Text, PasswordBX.Text))
             {
                 ErrorLBL.Visible = false;
                 PasswordBX.Clear();
                 UsernameBX.SelectAll();
                 var mf = new MainForm {
                     Opacity  = 0,
                     Lf       = this,
                     Location = new Point(Location.X - 50, Location.Y - 66),
                     User     = UsernameBX.Text[0].ToString().ToUpper() + UsernameBX.Text.Substring(1).ToLower()
                 };
                 mf.Show();
                 Hide();
             }
             else
             {
                 ErrorLBL.Visible = true;
             }
         }
     }
 }
Exemplo n.º 4
0
 private void UsernameBX_Enter(object sender, EventArgs e)
 {
     UsernameBX.SelectAll();
 }