How to fire Textbox textchanged event while typing in textbox

后端 未结 3 1199
感动是毒
感动是毒 2021-01-25 11:55

In my project i am using Textbox inside updatepanel to display the Receipt number which is not already exist in db table. But the textchanged event on the textbox is no

3条回答
  •  甜味超标
    2021-01-25 12:31

    two notes.

    1. Textchanged fires when the text box loses focus. You can use the keyd own or keypress events instead.

    2. Calling the server every time a user presses a key is not recommended. Consider using a timeout so you call the server only when the user finished typing (350 milliseconds is the standard I think) or pre load a list from the server and filter it client side.

    P.S.

    Do not use ASP.Net ajax... Just saying.

提交回复
热议问题