Ejemplo n.º 1
0
        public void bind()
        {
            string teachId = Request.QueryString["teachID"];
            string classId = Request.QueryString["classID"];
            string courseId = Request.QueryString["courId"];

               // ClassBLL classBll = new ClassBLL();
            CourseBLL courseBll = new CourseBLL();

            CommonBLL commonBll = new CommonBLL();

            //courseName.Text = classBll.get(classId).Name;
            courseName.Text = courseBll.get(courseId).Name;

            DataTable dt = commonBll.getCourseDetailAttendaceRate(teachId, classId, courseId, true);

            AspNetPager1.RecordCount = dt.Rows.Count;

            int from = (AspNetPager1.CurrentPageIndex - 1) * AspNetPager1.PageSize + 1;
            int to = from + AspNetPager1.PageSize - 1 > AspNetPager1.RecordCount ? AspNetPager1.RecordCount : from + AspNetPager1.PageSize - 1;

            GridView1.DataSource = PageUtil.getPaged(dt, from, to);
            GridView1.DataBind();
        }