Click here to Skip to main content
15,891,905 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
Hello sir,
I am using jquery multimonth calender on my page. I have two radiobuttons(Rd1, Rd2), two textboxes(Txt1, Txt2), two dropdownlists and one button control on my page. when ever i open the page and select the textbox multimonths datepicker is displaying well. but when ever i select any control like dropdownlist or radiobutton on the page( that means when ever the page postback and again ) and select the textbox multimonths datepicker is not displaying.
if anybodyknow plz help me.

Thank you. .
Posted
Comments
JF2015 26-Nov-10 3:35am    
Please don't repost your question.

This sounds like the view state of the date picker is not restored properly after a postback. Perhaps you should debug into the events prior and up to the load event of the control to see what happens after a postback.

Edit: And, before going through too much trouble, it is worth a look to see if the viewstate is activated for that control at all.
 
Share this answer
 
v2
hello sir.
thans for your reply. how can i set viewstate in javascript i am using datepicker like this.
XML
<script type="text/javascript">
            $(document).ready(function() {
                $("#<%= TxtToDate.ClientID %>").datepicker({ numberOfMonths: 2 });
                //                $("#txtDate").datepicker({ numberOfMonths: 2 });
            });
        </script>

where can set the viewstate here.
 
Share this answer
 
Comments
saini arun 26-Nov-10 4:05am    
Are you using update panels or any ajax control in your page?
[no name] 26-Nov-10 6:29am    
The first step would be to look into the properties of the control in the designer. There you can see the Viewstate property and if it is 'false', you can simply set it to 'true'. This might already be enough.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900