File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Swing / AWT / SWT and the fly likes Focus problem wiht Mac OS Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Focus problem wiht Mac OS" Watch "Focus problem wiht Mac OS" New topic

Focus problem wiht Mac OS

prashant gour
Ranch Hand

Joined: Feb 07, 2006
Posts: 45
I am validating one text field and showing one message box on putting wrong value in text field. Message box is coming up nicely but focus is remained in text filed where as i want focus should be on OK button of message box.

Any suggestions and thoughts!!!
Campbell Ritchie

Joined: Oct 13, 2005
Posts: 45358
What are you using as a message box? If you use something like JOptionPane that ought to keep the focus; JOptionPane is "modal."
Have you tried the requestFocus() methods for your message box?
I agree. Here's the link:
subject: Focus problem wiht Mac OS
It's not a secret anymore!