I have a asp.net web app. In my master page I have a calendar that is wrapped in an UpdatePanel (ajax).
I marked some of the days in my calendar using Calendar1.SelectedDates.Add(xxxx-xx-xx).
Now my problem is that when I click on one of the dates on my calender I “loses” all the marked dates, and only today date and the day I click is marked.
How can I save all the marked dates, so that when I click on one day they will keep those marked?
Thanks.
p.s I insert the marked days in the code behind on the master page
You have to store your selected dates in ViewState to leave them selected after postback/callback. You have also to add some logic to your code behind.
Please refer to the following link:
http://dotnetspeaks.net/post/Multiple-Date-Selection-inc2a0ASPc2a0Calendar.aspx