I've been searching for an answer to this and it has been posted on forums constantly since about 2005 but I'm still unable to find a solution.
I have a textbox with AutoPostback and a Textchanged event.
Yes, sadly I do need the postback and the event to fire. I've
tried explaining the problems with it but I need to validate the value entered there and then, and to do so I need to hit the DB.
Short of sending all the data I'd need down with the page and writing a complicated Javascript function to do the validation, I can't see any way out of the Postback.
The problem is that if the user edits the data in the Textbox and then clicks Save, the clicking of save causes the focus to leave the textbox thereby calling the Textchanged event. The page postsback and reloads as you'd expect, but the Save button's click event never fires.
The User has to click a second time on the Save button for it to work.
So? How to I fix this?
I can't have the page reloading when the user clicks save without a save actually happening. It fools me and I'm the developer, this is goign to screw users up completely.
-Rd