Esempio n. 1
0
 //登入
 private void button3_Click(object sender, EventArgs e)
 {
     try
     {
         if (Cls_JA_Member.VaildateUser(this.jA_Input5.輸入塊字串, this.jA_Input6.輸入塊字串))
         {
             this.Hide();
             MessageBox.Show("成功");
             JA_FancyMain fancyMain = new JA_FancyMain();
             fancyMain.FormClosing += (s, ee) =>
             {
                 this.Show();
             };
             fancyMain.Show();
         }
         else
         {
             this.jA_Input5.Focus();
             this.jA_Input5.輸入塊字串 = this.jA_Input6.輸入塊字串 = "";
             this.jA_Input5.警告    = System.Drawing.Color.FromArgb(244, 67, 54);
             this.jA_Input6.警告    = System.Drawing.Color.FromArgb(244, 67, 54);
         }
     }
     catch (Exception)
     {
         throw;
     }
 }
Esempio n. 2
0
 private void B_更改密碼_Click(object sender, EventArgs e)
 {
     if (Cls_JA_Member.VaildateUser(jA_Input1.輸入塊字串, jA_Input2.輸入塊字串))
     {
         this.新密碼_P.Visible = true;
         this.timer1.Start();
         int i = 0;
         this.timer1.Tick += delegate
         {
             if (i <= 350)
             {
                 i += 10;
                 this.驗證舊密碼_P.Left -= 10;
                 this.新密碼_P.Top    -= 10;
             }
             else
             {
                 i = 0;
                 this.驗證舊密碼_P.Visible = false;
                 this.timer1.Stop();
             }
         };
     }
     else
     {
         MessageBox.Show("資料錯誤");
     };
 }