This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes how to catch keyboard scrolling buttons event? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "how to catch keyboard scrolling buttons event?" Watch "how to catch keyboard scrolling buttons event?" New topic
Author

how to catch keyboard scrolling buttons event?

ankur rathi
Ranch Hand

Joined: Oct 11, 2004
Posts: 3830
onKeyPress is for all the buttons, I need sth specific to up, down, right and left arrow key.

TIA.
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Look at the keycode of the presses. They have ids.

Eric
ankur rathi
Ranch Hand

Joined: Oct 11, 2004
Posts: 3830
Originally posted by Eric Pascarello:
Look at the keycode of the presses. They have ids.

Eric


Thanks Eric.

But surprisingly, I am able to capture all the keys except up, down, right and left arrow key.

Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6


Eric
ankur rathi
Ranch Hand

Joined: Oct 11, 2004
Posts: 3830
Thanks a ton Eric.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: how to catch keyboard scrolling buttons event?
 
Similar Threads
What is it with the necktie?
About GUI
calling another GUI class
an array of buttons in an applet ?
Convert working program to display in GUI