We help IT Professionals succeed at work.

custom javascript for previous/next month links in <asp:calendar> control

prz_
prz_ asked
on
670 Views
Last Modified: 2013-11-05
I need to change the JavaScript that the <asp:calendar> control generates for the previous/next month links. I don't need to change what it does - just how it's written and how it behaves. I have the control load into modal dialogue window but clicking on the prev/next month links causes a new window to open with something like "javascript:__doPostBack('MyCalendar','V3135')" in the url and the control does nothing. From experimenting with the day links, which used to open a new window as well, I think that changing the links to <a href="javascript:;" onclick="__doPostBack('MyCalendar','V3135'); return false;>" with a dynamic date value will probably fix the problem, except I can't figure out how to make this change. How can I manipulate the script in these links? Or is there some other way to make the calendar behave and not open bogus new windows on me?

Thanks!
Comment
Watch Question

Commented:
This one is on us!
(Get your first solution completely free - no credit card required)
UNLOCK SOLUTION
Unlock the solution to this question.
Join our community and discover your potential

Experts Exchange is the only place where you can interact directly with leading experts in the technology field. Become a member today and access the collective knowledge of thousands of technology experts.

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.