Пример #1
0
        private void BindData()
        {
            DBLayer db = new DBLayer();
            DataSet report = new DataSet();
            // DataSet attendance = new DataSet();

            //report = db.GetMonthlyReportByStudentIDAndDate(Convert.ToInt32(Session["CurrentLoggedInStudent"].ToString()), DateTime.ParseExact("01/" + (uiDropDownListMonth.SelectedValue.Length == 1 ? "0" + uiDropDownListMonth.SelectedValue : uiDropDownListMonth.SelectedValue) + "/" + uiDropDownListYear.SelectedValue, "dd/MM/yyyy", null));
            report = db.GetMonthlyReportByStudentIDAndDate(Convert.ToInt32(Session["CurrentLoggedInStudent"].ToString()), DateTime.ParseExact("01/" + (uiDropDownListMonth.SelectedValue.Length == 1 ? "0" + uiDropDownListMonth.SelectedValue : uiDropDownListMonth.SelectedValue) + "/" + uiDropDownListYear.SelectedValue, "dd/MM/yyyy", null));
            //attendance = db.GetMonthlyAttendanceReportByStudentIDAndDate(Convert.ToInt32(Session["CurrentLoggedInStudent"].ToString()), DateTime.ParseExact("01/" + (uiDropDownListMonth.SelectedValue.Length == 1 ? "0" + uiDropDownListMonth.SelectedValue : uiDropDownListMonth.SelectedValue) + "/" + uiDropDownListYear.SelectedValue, "dd/MM/yyyy", null));

            uiRepeaterMonthlyReport.DataSource = report;
            uiRepeaterMonthlyReport.DataBind();

            //uiRepeaterAttendance.DataSource = attendance;
            //uiRepeaterAttendance.DataBind();

            //uiPanelAttendance.Visible = true;
            uiPanelReport.Visible = true;
        }