public IHttpActionResult Put(int id, [FromBody] UserDTO item) { IUserBDC userBDC = (IUserBDC)BDCFactory.Instance.Create(BDCType.UserBDC); IUserDTO userDTO = (IUserDTO)DTOFactory.Instance.Create(DTOType.UserDTO); userDTO.UserID = id; userDTO.UserName = item.UserName; userDTO.AccountBalance = item.AccountBalance; userDTO.BlockedAmount = item.BlockedAmount; userDTO.Contact = item.Contact; userDTO.DOB = item.DOB; userDTO.Email = item.Email; userDTO.UniqueUserId = item.UniqueUserId; userDTO.image = item.image; OperationResult <IUserDTO> retVal = userBDC.Update(userDTO); if (retVal.IsValid()) { return(Ok(retVal.Data)); } return(NotFound()); }