public override bool Save(object model, bool creating) { try { if (model != null) { var wcf = new WcfService.Service(); var obj = (AnagraficaFornitoreDto)model; bool performed = false; if (creating) { var newObj = wcf.CreateAnagraficaFornitore(obj); performed = (newObj != null); if (performed) { Update(obj, newObj); } } else //updating { performed = wcf.UpdateAnagraficaFornitore(obj); } return(performed); } } catch (Exception ex) { UtilityError.Write(ex); } return(false); }