public static bool AddNew(HDS_Question Que)
 {
     try
     {
         ExamSystemManagerDBEntities exMana = new ExamSystemManagerDBEntities();
         exMana.AddToHDS_Question(Que);
         exMana.SaveChanges();
     }
     catch (Exception e)
     {
         errMsg = e.Message;
         return false;
     }
     errMsg = "";
     return true;
 }
 public static bool Update(HDS_Question Que)
 {
     try
     {
         ExamSystemManagerDBEntities exMana = new ExamSystemManagerDBEntities();
         HDS_Question obj = exMana.HDS_Question.First(temp => temp.Que_ID == Que.Que_ID);
         obj.Lev_ID = Que.Lev_ID;
         obj.Cat_ID = Que.Cat_ID;
         obj.Typ_ID = Que.Typ_ID;
         obj.Que_Title = Que.Que_Title;
         obj.Que_Description = Que.Que_Description;
         exMana.SaveChanges();
     }
     catch (Exception e)
     {
         errMsg = e.Message;
         return false;
     }
     errMsg = "";
     return true;
 }
 /// <summary>
 /// Deprecated Method for adding a new object to the HDS_Question EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToHDS_Question(HDS_Question hDS_Question)
 {
     base.AddObject("HDS_Question", hDS_Question);
 }
 /// <summary>
 /// Create a new HDS_Question object.
 /// </summary>
 /// <param name="que_ID">Initial value of the Que_ID property.</param>
 public static HDS_Question CreateHDS_Question(global::System.Int32 que_ID)
 {
     HDS_Question hDS_Question = new HDS_Question();
     hDS_Question.Que_ID = que_ID;
     return hDS_Question;
 }