private void repTypes_Bound(object sender, System.Web.UI.WebControls.RepeaterItemEventArgs e) { int OriginalId = (int)DataBinder.Eval(e.Item.DataItem, "OriginalId"); Repeater repSessions = (Repeater)e.Item.FindControl("repSessions"); Label lblNone = (Label)e.Item.FindControl("lblNone"); if (repSessions != null) { DateTime StartDate = DateTime.MinValue; DateTime EndDate = DateTime.MinValue; //SetDates(ddPeriod.Value, out StartDate, out EndDate, fromDate.Text, toDate.Text); UserReport.GetDates(ddPeriod.Value, out StartDate, out EndDate, dtcStartDate.SelectedDate.ToShortDateString(), dtcEndDate.SelectedDate.ToShortDateString()); string sFilter = " " + LocRM.GetString("tGroupName") + ": " + ddContactGroup.SelectedItem.Text; sFilter += "<br/> " + LocRM.GetString("tPeriod") + ": " + StartDate.ToShortDateString() + " - " + EndDate.ToShortDateString(); _header.Filter = sFilter; repSessions.DataSource = UserReport.GetListIMSessionsByUserAndDate(OriginalId, StartDate, EndDate); repSessions.DataBind(); if (repSessions.Items.Count > 0) { lblNone.Visible = false; TotalImSessions += repSessions.Items.Count; } else lblNone.Text = LocRM.GetString("NoneDuring"); } }