コード例 #1
0
 /// <summary>
 /// 添加用户
 /// </summary>
 private void AddUser()
 {
     Form FrmUserInf = new Form_UserInf("");
     FrmUserInf.Tag = this.Tag;
     FrmUserInf.ShowDialog();
     if (FrmUserInf.DialogResult == DialogResult.OK)
     {
         LoadData();
     }
     this.dgv_Usermanage.CurrentCell = null;
 }
コード例 #2
0
 /// <summary>
 /// 修改用户
 /// </summary>
 private void AlterUser()
 {
     if (this.gv_UserManage.RowCount == 0 )
     {
         return;
     }
     //string strUserID = this.dgv_Usermanage.Rows[this.dgv_Usermanage.CurrentCell.RowIndex].Cells[0].Value.ToString();
     string strUserID = gv_UserManage.GetFocusedRowCellValue("sUserID").ToString();
     Form FrmUserInf = new Form_UserInf(strUserID);
     FrmUserInf.Tag = this.Tag;
     FrmUserInf.ShowDialog();
     if (FrmUserInf.DialogResult == DialogResult.OK)
     {
         LoadData();
     }
 }