Example #1
0
        public static CustomList <HouseKeepingValue> GetAllHouseKeepingValue(Int32 EntityID)
        {
            ConnectionManager conManager = new ConnectionManager(ConnectionName.HR);
            CustomList <HouseKeepingValue> HouseKeepingValueCollection = new CustomList <HouseKeepingValue>();
            IDataReader reader = null;
            String      sql    = "select *from HouseKeepingValue Where EntityID=" + EntityID;

            try
            {
                conManager.OpenDataReader(sql, out reader);
                while (reader.Read())
                {
                    HouseKeepingValue newHouseKeepingValue = new HouseKeepingValue();
                    newHouseKeepingValue.SetData(reader);
                    HouseKeepingValueCollection.Add(newHouseKeepingValue);
                }
                return(HouseKeepingValueCollection);
            }
            catch (Exception ex)
            {
                throw (ex);
            }
            finally
            {
                if (reader != null && !reader.IsClosed)
                {
                    reader.Close();
                }
            }
        }
Example #2
0
        public static CustomList <HouseKeepingValue> GetAllHouseKeepingValue(string search, string blank)
        {
            ConnectionManager conManager = new ConnectionManager(ConnectionName.HR);
            CustomList <HouseKeepingValue> HouseKeepingValueCollection = new CustomList <HouseKeepingValue>();

            IDataReader reader = null;
            String      sql    = search;

            try
            {
                conManager.OpenDataReader(sql, out reader);
                while (reader.Read())
                {
                    HouseKeepingValue newHouseKeepingValue = new HouseKeepingValue();
                    newHouseKeepingValue.SetData(reader);
                    HouseKeepingValueCollection.Add(newHouseKeepingValue);
                }
                HouseKeepingValueCollection.InsertSpName = "spInsertHouseKeepingValue";
                HouseKeepingValueCollection.UpdateSpName = "spUpdateHouseKeepingValue";
                HouseKeepingValueCollection.DeleteSpName = "spDeleteHouseKeepingValue";
                return(HouseKeepingValueCollection);
            }
            catch (Exception ex)
            {
                throw (ex);
            }
            finally
            {
                if (reader != null && !reader.IsClosed)
                {
                    reader.Close();
                }
            }
        }
Example #3
0
 public static CustomList<HouseKeepingValue> GetAllHouseKeepingValue(Int32 EntityID)
 {
     ConnectionManager conManager = new ConnectionManager(ConnectionName.HR);
     CustomList<HouseKeepingValue> HouseKeepingValueCollection = new CustomList<HouseKeepingValue>();
     IDataReader reader = null;
     String sql = "select *from HouseKeepingValue Where EntityID=" + EntityID;
     try
     {
         conManager.OpenDataReader(sql, out reader);
         while (reader.Read())
         {
             HouseKeepingValue newHouseKeepingValue = new HouseKeepingValue();
             newHouseKeepingValue.SetData(reader);
             HouseKeepingValueCollection.Add(newHouseKeepingValue);
         }
         return HouseKeepingValueCollection;
     }
     catch (Exception ex)
     {
         throw (ex);
     }
     finally
     {
         if (reader != null && !reader.IsClosed)
             reader.Close();
     }
 }
Example #4
0
        public static CustomList<HouseKeepingValue> GetAllHouseKeepingValue(string search, string blank)
        {
            ConnectionManager conManager = new ConnectionManager(ConnectionName.HR);
            CustomList<HouseKeepingValue> HouseKeepingValueCollection = new CustomList<HouseKeepingValue>();

            IDataReader reader = null;
            String sql = search;
            try
            {
                conManager.OpenDataReader(sql, out reader);
                while (reader.Read())
                {
                    HouseKeepingValue newHouseKeepingValue = new HouseKeepingValue();
                    newHouseKeepingValue.SetData(reader);
                    HouseKeepingValueCollection.Add(newHouseKeepingValue);
                }
                HouseKeepingValueCollection.InsertSpName = "spInsertHouseKeepingValue";
                HouseKeepingValueCollection.UpdateSpName = "spUpdateHouseKeepingValue";
                HouseKeepingValueCollection.DeleteSpName = "spDeleteHouseKeepingValue";
                return HouseKeepingValueCollection;
            }
            catch (Exception ex)
            {
                throw (ex);
            }
            finally
            {
                if (reader != null && !reader.IsClosed)
                    reader.Close();
            }
        }