public bool UpdateEvento(Evento c) { Evento even = this.Eventos.Find(c.Id); even.inicio = c.inicio; even.termino = c.termino; even.nombre = c.nombre; even.lugar = c.lugar; even.descripcion = c.descripcion; try { this.SaveChanges(); return true; } catch (Exception e) { return false; } }
public bool SaveNewEvento(Evento c) { this.Eventos.Add(c); this.SaveChanges(); return true; }