Exemple #1
0
 public static void UpdateUserPwd(string UserCode, string NewPwd, string OwnName)
 {
     try
     {
         EntityData entity = SystemManageDAO.GetSystemUserByCode(UserCode);
         try
         {
             if (entity.HasRecord())
             {
                 DataRow currentRow = entity.CurrentRow;
                 if (NewPwd != null)
                 {
                     currentRow["Password"] = NewPwd;
                 }
                 if (OwnName != null)
                 {
                     currentRow["OwnName"] = OwnName;
                 }
                 SystemManageDAO.UpdateSystemUser(entity);
             }
         }
         finally
         {
             entity.Dispose();
         }
     }
     catch (Exception exception)
     {
         throw exception;
     }
 }