Iam trying to use System.Web.UI.WebControls.Calender.
But when I select any date , It post backs automatically. Is there any way to avoid this behavior.
(I dont see the usual property AutoPostback which I set to False to avoid this behavior)
I need the selected date only once user submits the form.
Note- I am using VS2008
I generally avoid avoid the MS calender control because I find it so hard to work with and style. Have you considered something like the jQuery UI date picker, works as you need and far easier to style after too.
http://jqueryui.com/demos/datepicker/#inline
It posts back to set the selected form on the UI. what you can do is use a client side calendar (like jquery ui) or use ajax calendar extender so it will not postback the whole page.
It is possible with MS Calendar. You can customize content of each cell in DayRender event:
You can set e.Cell.Text to be div or span with text and javascript onclick event or link. You can put any HTML there.
Remember to add this code at the top of your page:
Remember, there is a forum about this topic where PLBlum says: