This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Focus question

 
Dominik Pawlocki
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all!!!
I wrote a small database and I want the errors to be describen in a small independent window which requests the focus completly.There is an error message (in that error window)and a small "ok" button, and I want to disable focus to my application completly until that button is pressed( then the error window disappears).I thought about the requestFocus() method, but it doesn't disable access to the other windows.I hope I made a clear explain ;-) English isn't my native language.
Thank's for help
 
Dave Vick
Ranch Hand
Posts: 3244
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dominik
Try a JOptionPane or some other dialog they are modal so will block the rest of the app until they go away.
hope that helps
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic