Пример #1
0
 private void FrmChangePass_Load(object sender, EventArgs e)
 {
     try
     {
         //验证登陆者身份
         //如果不符要求,要重新登录
         string Message = ""; bool HasError = true;
         bv.ValidateCard(LoginInMsg, ref Message, ref HasError);
         if (HasError)
         {
             MessageBox.Show(Message, "安全提醒", MessageBoxButtons.OK, MessageBoxIcon.Error);
             this.Hide();
             FrmLogin login = new FrmLogin();
             login.ShowDialog();
         }
     }
     catch (Exception ex)
     {
         Tips.TipsInfoBox(ex.Message);
     }
 }
Пример #2
0
 private void FrmOperationRecord_Load(object sender, EventArgs e)
 {
     try
     {
         //验证登陆者身份
         //如果不符要求,要重新登录
         string Message = ""; bool HasError = true;
         bv.ValidateCard(TheUser, ref Message, ref HasError);
         if (HasError)
         {
             MessageBox.Show(Message, "安全提醒", MessageBoxButtons.OK, MessageBoxIcon.Error);
             this.Hide();
             FrmLogin login = new FrmLogin();
             login.ShowDialog();
         }
     }
     catch (Exception ex)
     {
         Tips.TipsInfoBox(ex.Message);
     }
     dataGridView1.DataSource = BRecord.GetRecordTable(TheUser.AdminGuid);
 }
Пример #3
0
 private void FrmAddEmployee_Load(object sender, EventArgs e)
 {
     try
     {
         //验证登陆者身份
         //如果不符要求,要重新登录
         string Message = ""; bool HasError = true;
         bv.ValidateCard(SystemMsg, ref Message, ref HasError);
         if (HasError)
         {
             MessageBox.Show(Message, "安全提醒", MessageBoxButtons.OK, MessageBoxIcon.Error);
             this.Hide();
             FrmLogin login = new FrmLogin();
             login.ShowDialog();
         }
     }
     catch (Exception ex)
     {
         Tips.TipsInfoBox(ex.Message);
     }
     Tb_EmlpoyeeCode.Text = DateTime.Now.ToString("yyyyMMddHHmmss");
     Tb_CreateDate.Text   = DateTime.Now.ToString("yyyy年MM月dd日 HH时mm分");
     Tb_BelongTo.Text     = SystemMsg.AdminNickName;
 }
Пример #4
0
 private void FrmAllot_Load(object sender, EventArgs e)
 {
     try
     {
         //验证登陆者身份
         //如果不符要求,要重新登录
         string Message = ""; bool HasError = true;
         bv.ValidateCard(LoginMsg, ref Message, ref HasError);
         if (HasError)
         {
             MessageBox.Show(Message, "安全提醒", MessageBoxButtons.OK, MessageBoxIcon.Error);
             this.Hide();
             FrmLogin login = new FrmLogin();
             login.ShowDialog();
         }
     }
     catch (Exception ex)
     {
         Tips.TipsInfoBox(ex.Message);
     }
     EmployNum            = be.GetEmployNum(LoginMsg.AdminGuid);
     Tb_EmployeeNum2.Text = EmployNum.ToString();
     Tb_EmployeeNum1.Text = EmployNum.ToString();
 }