title: Entity Update is not working, no error in update process.
body: <p>There is no error and newUser object is found on database but database is not modified. Whats the problem. As new learner, elaborate answer is much appreciated. thanks.</p>
  
  <pre><code>TBL_LogIn newUser = new TBL_LogIn();
  newUser = hrmsDb.TBL_LogIn.Where(x =&gt; x.EmployeeID == inputEmployeeID).FirstOrDefault();
  try
  {
      if (newUser != null)
      {
          AddLogInInfo(newUser);
          hrmsDb.Entry(newUser).State = EntityState.Modified; 
          hrmsDb.SaveChanges();
      }
      else
      { }
  }
  catch (Exception ex)
  {
      throw;
  }
  
  /*-----Functions to Update New Employee Information in Three tables-------*/
  private void AddLogInInfo(TBL_LogIn newUser)
  {
      string UserName = TextBoxUsername.Text;
      string Password = TextBoxPassword.Text;
      string UserType = TextBoxUserType.Text;
  
      newUser.UserName = UserName;
      newUser.PassWord = Password;
      newUser.UserType = UserType;
  }
  </code></pre>