示例#1
0
 public bool Delete()
 {
     try
     {
         MonamurDBDataSetTableAdapters.ProceduresTableAdapter t_procedTableAdap = new MonamurDBDataSetTableAdapters.ProceduresTableAdapter();
         t_procedTableAdap.DeleteProcedure(ID);
         return(true);
     }
     catch {
         return(false);
     }
 }
示例#2
0
 public bool InsertProcedure()
 {
     try
     {
         MonamurDBDataSetTableAdapters.ProceduresTableAdapter t_procedTableAdap = new MonamurDBDataSetTableAdapters.ProceduresTableAdapter();
         t_procedTableAdap.InsertProcedure(ProcedureName, AnimalID, Cost, Info);
         return(true);
     }
     catch {
         return(false);
     }
 }
示例#3
0
 public void GetInfoByProcId()
 {
     MonamurDBDataSetTableAdapters.ProceduresTableAdapter t_procedTableAdap = new MonamurDBDataSetTableAdapters.ProceduresTableAdapter();
     MonamurDBDataSet.ProceduresDataTable t_procedDataTable = new MonamurDBDataSet.ProceduresDataTable();
     t_procedTableAdap.FillById(t_procedDataTable, ProcedureID);
     ProcedureName = t_procedDataTable.Rows[0]["procedure_name"].ToString();
     if (t_procedDataTable.Rows[0]["cost"].ToString() != String.Empty)
     {
         Cost = Convert.ToInt32(t_procedDataTable.Rows[0]["cost"]);
     }
     Info = t_procedDataTable.Rows[0]["info"].ToString();
 }