public override void DataBind() { using (ReportDal DataAccess = new ReportDal()) { String YearMonth = txtYearMonth.Text; String SpecialField = Request.Params["SpecialField"]; string position = ddlPosition.SelectedValue; if (!string.IsNullOrEmpty(YearMonth) && (YearMonth.Length > 6)) { YearMonth = YearMonth.Substring(0, 4) + YearMonth.Substring(5, 2); } List <PersonScoreEntity> resultDataList = DataAccess.GetPersonScore(YearMonth, SpecialField); if (position != "ALL") { resultDataList = resultDataList.Where(r => r.PositionID == position).ToList(); } PersonScoreRepeater.DataSource = resultDataList; } base.DataBind(); ColSpan(); }