/// <summary>
 /// Create a new RdrEventLog object.
 /// </summary>
 /// <param name="eventID">Initial value of the EventID property.</param>
 /// <param name="errorCode">Initial value of the ErrorCode property.</param>
 /// <param name="description">Initial value of the Description property.</param>
 /// <param name="eventDate">Initial value of the EventDate property.</param>
 /// <param name="readerID">Initial value of the ReaderID property.</param>
 public static RdrEventLog CreateRdrEventLog(global::System.Int32 eventID, global::System.Byte errorCode, global::System.String description, global::System.DateTime eventDate, global::System.Int16 readerID)
 {
     RdrEventLog rdrEventLog = new RdrEventLog();
     rdrEventLog.EventID = eventID;
     rdrEventLog.ErrorCode = errorCode;
     rdrEventLog.Description = description;
     rdrEventLog.EventDate = eventDate;
     rdrEventLog.ReaderID = readerID;
     return rdrEventLog;
 }
Beispiel #2
0
 // Save Rdr Event log
 private void SaveRdrEventLog(short _RdrID, string _Description, byte _ErrorCode)
 {
     using (var context = new TAS2013Entities())
     {
         RdrEventLog _rdrEventLog = new RdrEventLog();
         _rdrEventLog.ReaderID = _RdrID;
         _rdrEventLog.Description = _Description;
         _rdrEventLog.ErrorCode = _ErrorCode;
         _rdrEventLog.EventDate = DateTime.Now;
         context.RdrEventLogs.AddObject(_rdrEventLog);
         context.SaveChanges();
     }
 }
 /// <summary>
 /// Deprecated Method for adding a new object to the RdrEventLogs EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToRdrEventLogs(RdrEventLog rdrEventLog)
 {
     base.AddObject("RdrEventLogs", rdrEventLog);
 }