This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes JOptionPane.showMessageDialog  BLOCKS my application when switching to somthing else Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JOptionPane.showMessageDialog  BLOCKS my application when switching to somthing else" Watch "JOptionPane.showMessageDialog  BLOCKS my application when switching to somthing else" New topic
Author

JOptionPane.showMessageDialog BLOCKS my application when switching to somthing else

Peter Primrose
Ranch Hand

Joined: Sep 10, 2004
Posts: 755


this one drives me crazy.

The code below will show the message "msg: 884R, Chcek your account!" when the user log to the system.

THE PROBLEM: say the user activate the application and recieved this message, and then he switches to a different application (e.g, IE) and returns to the application - HE DOESN'T SEE THE MESSAGE, hence, the application is BLOCKED!!! :-(

ANYONE???!?!?!

if (secDB.pendingUsers())
{
Component c = SwingUtilities.getRoot((Component)e.getSource());
JFrame parentFrame = (JFrame)c; JOptionPane.showMessageDialog(parentFrame, "msg: 884R, Chcek your account!");
}
 
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
 
subject: JOptionPane.showMessageDialog BLOCKS my application when switching to somthing else
 
It's not a secret anymore!