Ejemplo n.º 1
0
 private EntityHandler.SubObjects ConvertToObject(DataRow row)
 {
     EntityHandler.SubObjects obj = new EntityHandler.SubObjects();
     try
     {
         obj.MainObjectCode = row["MainObjectCode"].ToString();
         obj.SubObjectCode  = row["SubObjectCode"].ToString();
     }
     catch (Exception ex)
     { }
     return(obj);
 }
Ejemplo n.º 2
0
        public bool Delete(EntityHandler.SubObjects obj)
        {
            bool Status = false;

            try
            {
                Status = new DataAccessHandler.SubObjects().Delete(obj);
            }
            catch (Exception ex)
            { }
            return(Status);
        }
Ejemplo n.º 3
0
        public DataTable SelectAll(EntityHandler.SubObjects obj)
        {
            DataTable dt = new DataTable();

            try
            {
                string SqlCommand = "";

                dt = new DALBase().Select(SqlCommand);
            }
            catch (Exception ex)
            { }
            return(dt);
        }
Ejemplo n.º 4
0
        public bool Delete(EntityHandler.SubObjects obj)
        {
            bool Status = false;

            try
            {
                string SqlCommand = "";

                Status = new DALBase().Update(SqlCommand);
            }
            catch (Exception ex)
            { }
            return(Status);
        }
Ejemplo n.º 5
0
        private EntityHandler.SubObjects ConvertToObject(DataRow row)
        {
            EntityHandler.SubObjects obj = new EntityHandler.SubObjects();
            try
            {

                obj.MainObjectCode = row["MainObjectCode"].ToString();
                obj.SubObjectCode = row["SubObjectCode"].ToString();
              

            }
            catch (Exception ex)
            { }
            return obj;
        }
Ejemplo n.º 6
0
        public List <EntityHandler.SubObjects> SelectAll(EntityHandler.SubObjects obj)
        {
            List <EntityHandler.SubObjects> listobj = new List <EntityHandler.SubObjects>();

            try
            {
                DataTable dt = new DataAccessHandler.SubObjects().SelectAll(obj);
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    listobj.Add(ConvertToObject(dt.Rows[i]));
                }
            }
            catch (Exception ex)
            { }
            return(listobj);
        }