I've got a class that has a keyListener in it. When i implement the keyTyped(KeyEvent evt) method the event parameter always has a keyCode value of 0 and a keyChar which matches the key typed.
Does anyone know if there is a way to get a keyCode from a keyChar when using KeyEvents?
this is part of it...
int keycode = (int)keyChar;
But if it's a lowercase char, you need to subtract 32 from it. And that's only good for ASCII chars (which is okay, really cuz there's no VK_ values for much else.