Datepicker onKeyUp?

2 posts, 0 answers
  1. Mike
    Mike avatar
    26 posts
    Member since:
    Dec 2006

    Posted 18 Sep 2008 Link to this post

    I am using the 'OnDateSelected' to do some checks when the date is changed but I also need to check when they type into the textbox and change the date. I tried adding the onKeyUp event to my datepicker on form load but it does not fire.
    The problem is that I enable/disable a button if any thing on the form has changed. If they pick a different date via the calendar the OnDateSelected fires and the button is enabled. If they then type in the textbox and change the date back to the original and click the button, the page freezes because my javascript is trying to disable the button (OnDateSelected fires when the textbox loses focus) at the same time the page is trying to do a postback The button shows in the pressed state and the page just sits there.
  2. Maria Ilieva
    Maria Ilieva avatar
    4017 posts

    Posted 23 Sep 2008 Link to this post

    Hello Mike,

    You could try using the OnKeyPress event in order to verify whether the user presses a key to enter a value. It does not occur when the user presses navigation keys, the delete key, and so on.

    Maria Ilieva
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Back to Top