How to fire TextBox.TextChanged event on jquery onkeyup?

I have asp.net TextBox with ontextchanged event this is search text box in my application.

I have search code in this event. how can I fire this event with the help of j query onkeyup.

If i enter text in text box it will fire ontextchanged without press enter or mouse.

This is an example of event what i need. But i dont know how to fire ontextchanged on this.

http://viralpatel.net/blogs/demo/sum-textbox-value-javascript.html

Answers:

Thank you for visiting the Q&A section on Magenaut. Please note that all the answers may not help you solve the issue immediately. So please treat them as advisements. If you found the post helpful (or not), leave a comment & I’ll get back to you as soon as possible.

Method 1

$('#textMessage').keyup(function(event) {
  if (event.keyCode == 13) {
    var message =  $('#textMessage').val();
    alert(message);
  } else {
    return true;
  }
}); //endTextMessage keyup


All methods was sourced from stackoverflow.com or stackexchange.com, is licensed under cc by-sa 2.5, cc by-sa 3.0 and cc by-sa 4.0

0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x