Reputation: 686
I am wondering about how to detect "Next" button event on android numeric keypad using Jquery. Please give me solution how to trigger that button event.
Upvotes: 3
Views: 3176
Reputation: 500
You can detect the next
keyboard press by using the following bind in JQuery:
$('input').on('keydown', function(e){
if(e.which === 9) {
//your code here
}
});
The 'next' button emulates the tab
keypress event on a keyboard, which is key code 9. Unfortunately, keypress and keyup events do not detect the next
key event, so you need to bind it on keydown
.
Upvotes: 7