コード例 #1
0
ファイル: UserQuestion.cs プロジェクト: baluragala/IDS-P-001
        public void SaveQuestion(UserQuestion userQuestion)
        {
            tbl_UserQuestions entity = new tbl_UserQuestions
            {
               CreatedBy="mobile",
               CreatedDate = DateTime.Now,
               Question = userQuestion.Question,
               UserId = userQuestion.UserId
            };

            db.tbl_UserQuestions.AddObject(entity);
            db.SaveChanges();
        }
コード例 #2
0
 /// <summary>
 /// Deprecated Method for adding a new object to the tbl_UserQuestions EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddTotbl_UserQuestions(tbl_UserQuestions tbl_UserQuestions)
 {
     base.AddObject("tbl_UserQuestions", tbl_UserQuestions);
 }
コード例 #3
0
 /// <summary>
 /// Create a new tbl_UserQuestions object.
 /// </summary>
 /// <param name="question_Id">Initial value of the Question_Id property.</param>
 /// <param name="question">Initial value of the Question property.</param>
 /// <param name="userId">Initial value of the UserId property.</param>
 /// <param name="createdBy">Initial value of the CreatedBy property.</param>
 /// <param name="createdDate">Initial value of the CreatedDate property.</param>
 public static tbl_UserQuestions Createtbl_UserQuestions(global::System.Int32 question_Id, global::System.String question, global::System.Int32 userId, global::System.String createdBy, global::System.DateTime createdDate)
 {
     tbl_UserQuestions tbl_UserQuestions = new tbl_UserQuestions();
     tbl_UserQuestions.Question_Id = question_Id;
     tbl_UserQuestions.Question = question;
     tbl_UserQuestions.UserId = userId;
     tbl_UserQuestions.CreatedBy = createdBy;
     tbl_UserQuestions.CreatedDate = createdDate;
     return tbl_UserQuestions;
 }