Why form is getting freeze when trying to make changes?