コード例 #1
0
 public void SaveScore(TbScore score)
 {
     using (var dc = new tbscoresEntities())
     {
         score.ID = Guid.NewGuid();
         dc.AddToTbScores(score);
         dc.SaveChanges();
     }
 }
コード例 #2
0
 /// <summary>
 /// Deprecated Method for adding a new object to the TbScores EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToTbScores(TbScore tbScore)
 {
     base.AddObject("TbScores", tbScore);
 }
コード例 #3
0
 /// <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;
 }