private void SetupCalendarItem(TableCell cell, DataRow r, ITemplate t) { // given a calendar cell and a datarow, set up the // templated item and resolve data binding syntax // in the template DataCalendarItem dti = new DataCalendarItem(r); t.InstantiateIn(dti); if (r != null) { if (cell.CssClass.Length > 0) { cell.CssClass = cell.CssClass + " daywithevents"; } else { cell.CssClass = "daywithevents"; } dti.DataBind(); } cell.Controls.Add(dti); }
private void SetupCalendarItem(TableCell cell, DataRow r, ITemplate t) { // given a calendar cell and a datarow, set up the // templated item and resolve data binding syntax // in the template DataCalendarItem dti = new DataCalendarItem(r); t.InstantiateIn(dti); if (r != null) { if (cell.CssClass.Length > 0) { cell.CssClass = cell.CssClass + " daywithevents"; } else { cell.CssClass = "daywithevents"; } dti.DataBind(); } cell.Controls.Add(dti); }