Monday, March 26, 2012

Preventing onTextChanged event

I have a small conundrum with a databound textbox and an AJAX Masked Edit Extender control that formats the textbox input to a date. My problem is that I need to confirm user input on a control and send an email if a date is added to the box, I am using the textbox OnTextChange event to send the notification when the page is posted. However, if a date has already been entered, the Ajax control reformats the date captured from the database and causes the OnTextChanged event for the textbox to fire. I only want that event to fire if a user puts a date in that field not if the field is reformatted by the AJAX control.I am at a loss as to how to prevent the control from firing that event considering it is actually changing the text.

Thanks for any help,

I recommend using Teleriks Input control. Then you need zero programming for this. Its worth the grand if you doing this professionally.

No comments:

Post a Comment