Click here to Skip to main content
15,906,097 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I have a DataEntry screen where I need to give the users a provision to select date and for that I've used a Date Picker control. The problem is when I'm clicking on the next button to change the month the calender is not staying on the screen in order to select other month the user has to click on the button multiple times. Please find below exactly what I'm saying.

1.I click on the calendar icon the calendar pops up

2. Now user tries to navigate months (i.e from June to July or June to May) using next/prev buttons on calendar

3. When navigating from current month to Next/Prev month, I want the calender to be shown on the screen. But on click of the next/prev button one postback is happening and hence I am loosing the popped calender.

4. I suppose, I can achieve the selected date using OnSelectionChanged event handler which makes a post back.

5. But with the post back I lose the popped calendar as the calendar is loaded again.

6. The user needs to click on the calendar icon again to if he wants to navigate to another month.

Is there any way to keep the calender on the screen during the month got changed? Any help is greatly appreciated.
Posted
Updated 9-Aug-10 4:14am
v2
Comments
TheyCallMeMrJames 9-Aug-10 10:38am    
Which control are you using? The ASP.NET Ajax extender or other? Edit: check that, you're not using Ajax or you wouldn't get the postback interference. Can you use the Ajax extender or jQuery?

1 solution

You should search for a javascript calendar control on the web and use that. The built in one in ASP.NET is kind of rubbish.
 
Share this answer
 
Comments
Bodan_ 12-Aug-10 11:22am    
Hi Christian, Thank you for the advice, I've already solved this problem using javascript. But now I have one more requirement, I need to give users a provision to select date from an editable gridview. I've added a textbox on edittemplate section of the gridview and tried using Ajax Calender Extender but in vain. Doing this I'm getting some weird javascreen popup saying "There was some error. DO you want to debug?" and after that nothing was shown on the browser. Could you please suggest any other option to accomplish this requirement. I'm using .NET 3.5. Thanks in advance.

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