Hello Everyone,
I am having a problem while upgrading application from JDK 1.1.8 to JDK 1.5.0_12. The "KeyPressedEvent" of textfield track almost all key events and works accordingly but when TAB key is pressed then there is no response. But the same application works fine in JDK 1.1.8 and all key pressed are tracked and prints accordingly.
public class Test extends KeyListenerFrame{
-----
void txtKey_keyPressed(KeyEvent e) throws Exception
{
System.out.println("keys::"+e.getKeyCode());
if (e.getKeyCode() == KeyEvent.VK_TAB || e.getKeyCode() == KeyEvent.VK_ENTER)
{
System.out.println("Key pressed:1:"+e.getKeyCode());
}
}
}
Can anybody suggest me how to track key pressed for TAB key in textfield using JDK 1.5.
Thank you.
Edited by: ritesh163 on Nov 15, 2009 10:08 AM