コード例 #1
0
ファイル: NhomTin.cs プロジェクト: nhatkycon/AoCuoiHongNhung
        public static NhomTinCollection SelectAll()
        {
            NhomTinCollection List = new NhomTinCollection();

            using (IDataReader rd = SqlHelper.ExecuteReader(DAL.con(), CommandType.StoredProcedure, "tblRss_sp_tblRssNhomTin_Select_SelectAll_linhnx"))
            {
                while (rd.Read())
                {
                    List.Add(getFromReader(rd));
                }
            }
            return(List);
        }
コード例 #2
0
ファイル: NhomTin.cs プロジェクト: nhatkycon/AoCuoiHongNhung
        public static NhomTinCollection SelectByNhomId(string Nid)
        {
            NhomTinCollection List = new NhomTinCollection();

            SqlParameter[] obj = new SqlParameter[1];
            obj[0] = new SqlParameter("Nid", Nid);
            using (IDataReader rd = SqlHelper.ExecuteReader(DAL.con(), CommandType.StoredProcedure, "tblRss_sp_tblRssNhomTin_Select_SelectByNid_linhnx", obj))
            {
                while (rd.Read())
                {
                    List.Add(getFromReader(rd));
                }
            }
            return(List);
        }
コード例 #3
0
ファイル: NhomTin.cs プロジェクト: nhatkycon/AoCuoiHongNhung
        public static NhomTinCollection SelectByNhomDanhMuc(SqlConnection con, int top, string DM_Ma)
        {
            NhomTinCollection List = new NhomTinCollection();

            SqlParameter[] obj = new SqlParameter[2];
            obj[0] = new SqlParameter("top", top);
            obj[1] = new SqlParameter("DM_Ma", DM_Ma);
            using (IDataReader rd = SqlHelper.ExecuteReader(con, CommandType.StoredProcedure, "tblRss_sp_tblRssNhomTin_Select_SelectByNhomDanhMuc_linhnx", obj))
            {
                while (rd.Read())
                {
                    List.Add(getFromReader(rd));
                }
            }
            return(List);
        }