Пример #1
0
        public void dataBind()
        {
            int count = Convert.ToInt32(ConfigurationManager.AppSettings["CMSCount"]);
            int page  = Convert.ToInt32(ConfigurationManager.AppSettings["CMSPage"]);

            EtNet_BLL.DataPage.Data data = new EtNet_BLL.DataPage.Data();
            DataSet ds = data.DataPage("Factory", "Id", "*", "", "Id", true, count, page, pages);

            rpCompany.DataSource = ds;
            rpCompany.DataBind();
        }
Пример #2
0
        /// <summary>
        /// 加载数据
        /// </summary>
        private void LoadInformationNoticeData()
        {
            DataTable strtbl   = Exists();
            string    strfixed = " AND recipientid = " + ((EtNet_Models.LoginInfo)Session["login"]).Id;

            strfixed += " AND sendtime <= '" + DateTime.Now.ToString() + "'";

            string str = Session["query"].ToString();

            int pitem  = int.Parse(strtbl.Rows[0]["pageitem"].ToString());
            int pcount = int.Parse(strtbl.Rows[0]["pagecount"].ToString());

            EtNet_BLL.DataPage.Data data = new EtNet_BLL.DataPage.Data();
            DataSet tbl = data.DataPage("ViewInformationNotice", "id", "*", strfixed + str, "id", true, pitem, pcount, pages);

            this.rptinformation.DataSource = tbl;
            this.rptinformation.DataBind();
        }