I'm using a KeyListener interface and writing code for the three methods required. keyPressed() keyReleased() keyTyped() Can someone please explain to me why keyPressed() and keyReleased() seem to the be the only actions understood. The description of keyTyped sounds like when I type a key it should be invoked - but nothing is happening. Thanks for any help. Paul
Hi Paul, It depends on what source you are using for the KeyListener. The code below works for me under JDK1.2.
If I remember correctly the TextField has some "bug" in it that keyTyped doesn't get called for every keystroke. I think that is because the TextField intercepts the keys and only lets some of them through... Regards, Manfred.
Joined: Mar 15, 2000
It's actually a TextField I'm using so that probably explains the problem. I've managed to get working what I need to get working anyway. Thanks a lot. Paul