SyntaxFix
Write A Post
Hire A Developer
Questions
Try this one,
myFrame.setVisible(true); EventQueue.invokeLater(new Runnable() { @Override public void run() { myComponent.grabFocus(); myComponent.requestFocus();//or inWindow } });