Calendar control - limit possible months?

G

Guest

How can I limit the possible months a user can navigate to in the calendar
control? I only want users to be able to select dates from the current year
and the previous year. Is that possible?
 
R

Riki

lanem said:
How can I limit the possible months a user can navigate to in the calendar
control? I only want users to be able to select dates from the current
year
and the previous year. Is that possible?

To prevent selection only, add a RangeValidator to the calendar. Don't
forget to set the type as "Date".
But this will not prevent navigation.

To prevent navigation on the client, I don't know. On the server, handle the
VisibleMonthChanged event.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,905
Latest member
Kristy_Poole

Latest Threads

Top