views:

20

answers:

1

Hi
I have a JFrame and some JButtons JLabels and a JTextfield
I need to create a keyboard shortcut to when it pressed the JTextfield get focus
How can I do this?

Thanks

+1  A: 

Maybe you are looking for:

label.setLabelFor( textField );

Otherwise you need to use Key Bindings.

camickr