private void LoadYearCombo() { //Set the combo data source cmbYear.DataSource = PeriodUtils.GetYears(); cmbYear.DataBind(); cmbYear.SelectedIndex = cmbYear.Items.Count - 1 - ApplicationConstants.YEAR_AHEAD_TO_INCLUDE; /*select curent year*/ }
private void LoadYearCombo() { cmbYear.Items.Add(new Telerik.Web.UI.RadComboBoxItem(String.Empty, ApplicationConstants.INT_NULL_VALUE.ToString())); cmbYear.DataSource = PeriodUtils.GetYears(); cmbYear.DataBind(); cmbYear.Text = DateTime.Now.Year.ToString(); }