Пример #1
0
 // 公用静态方法,删除一条记录 DeleteQiYeLeiXing
 public static bool DeleteEntity(QiYeLeiXingBusEntity obj)
 {
     if (obj == null || obj.IsEmpty)
     {
         return false;
     }
     QiYeLeiXingDelete exec = new QiYeLeiXingDelete();
     try
     {
         exec.ReceiveParameter(obj);
         exec.ExecNoQuery();
         return true;
     }
     catch (Exception ex)
     {
         //throw ex;
         return false;
     }
     finally
     {
         obj = null;
     }
 }
Пример #2
0
 // 物理删除由主键ID指定的一条记录 DeleteQiYeLeiXing
 public bool Delete(int ID)
 {
     QiYeLeiXingDelete exec = new QiYeLeiXingDelete();
     try
     {
         exec.ID = ID;
         exec.ExecNoQuery();
         return true;
     }
     catch (Exception ex)
     {
         //throw ex;
         return false;
     }
     finally
     {
         exec = null;
     }
 }