ASP.NET Calendar - Knowledge Base

« Back to Knowledge Base list

Display a range of dates

Q:

Can I only display a range of dates?

A:

Calendar can have a minimum date allowed. Any date lower than this date is disabled.
Also can have a maximum date allowed. Any date greater than this date is disabled.

C#
        Calendar1.DateMin = DateTime.Now;
        Calendar1.DateMax = DateTime.Now.AddDays(10);


VB.NET
        Calendar1.DateMin = DateTime.Now;
        Calendar1.DateMax = DateTime.Now.AddDays(10);