Does your KeyListener get called? Have to added some debug statements to test this? If yes, the problem may lie in the logic. If no, the problem may lie in the component not having focus (in which...