ASP.NET Calendar - Tutorial - Year selector

You may enable a div based or a drop down box with a list of years by setting ShowYearSelector to true.

By default, the year selector is not shown.

When enabled, year selector includes a range between ±10 years from current date.
If you need more years, then you must set either DateMin or DateMax properties.
Then calendar will use these values for its year selector range. When HtmlList type is used you can set YearMinScroll or YearMaxScroll properties. Years between these values will be shown without scrolling.

 
 
2005
2006
2007
2008
2009
2010
2011
2012
2014
 
 
<obout:Calendar runat="server"
     ShowYearSelector="true"
     YearSelectorType="HtmlList"
     DateMin="1/1/1980"
     DateMax="12/31/2020"
     YearMinScroll="2005"
     YearMaxScroll="2012"
</obout:Calendar>
<obout:Calendar runat="server"
     ShowYearSelector="true"
     YearSelectorType="DropDownList"
     DateMin="1/1/1980"
     DateMax="12/31/2020"
</obout:Calendar>

"Incredibly efficient OBOUT suite!"

Steve Poirier
TELUQ, Quebec

Random testimonial   All testimonials