Fire event on enter key press for a textbox

后端 未结 10 1475
[愿得一人]
[愿得一人] 2020-12-01 02:05

I have the following asp.net textbox control.


After the user writes something in this

10条回答
  •  遥遥无期
    2020-12-01 02:41

    Try follow: Aspx:

        
    
    

    JS:

    function EnterEvent(e, callback) {
            if (e.keyCode == 13) {
                callback();
            }
        }
    

提交回复
热议问题