This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes How to creating an Alert Dialog window? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "How to creating an Alert Dialog window?" Watch "How to creating an Alert Dialog window?" New topic
Author

How to creating an Alert Dialog window?

Tom Patrick
Ranch Hand

Joined: Oct 24, 2000
Posts: 30
I want to create a window to pop up that tells a user an error has occured that looks like the ones that normally pop up in Windows (centered on screen, with an icon, single or up to 3 buttons such as "OK", "Cancel", "Yes", "No").
Is there a class that does this? Matching a windows Alert Dialog Box exactly is not required, but would be preferred.
Thanks
Kathy Lynch
Greenhorn

Joined: Feb 26, 2001
Posts: 25
Javax Swing has an JOptionPane class that has a .showConfirmDialog method that has the Yes/No/Cancel options you mentioned.
[This message has been edited by Kathy Lynch (edited March 09, 2001).]
Siva Prasad
Ranch Hand

Joined: Feb 22, 2001
Posts: 104
If you just have a look at the class JOptionPane in javax(java swing) classes, you will find the all kind of dialogs you need.
Just explore this class in JDK documentation.
HTH
cheers
Siva Prasad
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: How to creating an Alert Dialog window?
 
Similar Threads
How do i create animated alert on specific interval ?
href in a new window
pop up window+javascript
Help on how to change caption of Confirm box in JSP
javascript:window.close() not working in firefox