Computer Science Canada

KeyListener

Author:  communismisntdead [ Tue May 18, 2004 1:42 pm ]
Post subject:  KeyListener

Hey, I've been trying to receive numerical input from the user using a frame called by an application, and I can't seem to get it to work. I've been toying around with something like "key.keyTyped (KeyEvent.getKeyChar ())" but it's been giving me errors... Can anyone clear this up? Thanks...

Author:  Master [ Fri May 21, 2004 3:54 pm ]
Post subject: 

method:

public void keyPressed(KeyEvent event)

if (event.getKeyCode() == event.VK_RIGHT) // typed right arrowkey

you can look in the java api
- go to www.google.com then type "java api" and the first link will take you there then in the left frame look for KeyEvent


: