public void SaveScore(TbScore score) { using (var dc = new tbscoresEntities()) { score.ID = Guid.NewGuid(); dc.AddToTbScores(score); dc.SaveChanges(); } }
/// <summary> /// Deprecated Method for adding a new object to the TbScores EntitySet. Consider using the .Add method of the associated ObjectSet<T> property instead. /// </summary> public void AddToTbScores(TbScore tbScore) { base.AddObject("TbScores", tbScore); }
/// <summary> /// Create a new TbScore object. /// </summary> /// <param name="id">Initial value of the ID property.</param> public static TbScore CreateTbScore(global::System.Guid id) { TbScore tbScore = new TbScore(); tbScore.ID = id; return tbScore; }