private void OpenDeleteErrorCode(object obj)
 {
     if (SelectedErrorCode != null && SelectedErrorCodes.Contains(SelectedErrorCode))
     {
         SelectedErrorCodes.Remove(SelectedErrorCode);
     }
 }
 private void Page_Disappearing(object sender, EventArgs e)
 {
     if (chooseCodeVM.ReturnResult == true)
     {
         if (!SelectedErrorCodes.Select(er => er.Id).Contains(chooseCodeVM.SelectedCode.Id))
         {
             SelectedErrorCodes.Add(chooseCodeVM.SelectedCode);
         }
     }
 }