IntelliJ Java IDE
The moose likes Swing / AWT / SWT / JFace and the fly likes creating Modal Dialog box.(urgent) Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT / JFace
Reply Bookmark "creating Modal Dialog box.(urgent)" Watch "creating Modal Dialog box.(urgent)" New topic
Author

creating Modal Dialog box.(urgent)

netharam ram
Ranch Hand

Joined: Aug 09, 2001
Posts: 202
How can I create modal Dialog box.Sorry, I'm not sure about modal & modaless.
I want to create a Dialog box that should not give access to any other application without responding it.Urgent please.
Paul Stevens
Ranch Hand

Joined: May 17, 2001
Posts: 2823
Can I ask why you want to make an application modal to all other applications on a system? Why shouldn't a user be allowed to go to another application?
ps I don't think there is anything within java that will do this.
You can make it modal within your application.
netharam ram
Ranch Hand

Joined: Aug 09, 2001
Posts: 202
Sorry paul u misunderstood my question.My intention is not to restrict the user but to inform the user,i.e attract the user over my application.Moreover I didn't mean to make my application modal,reather just a dialog box.My problem is when a confirmation box appears behind any other application it is left un-noticed until all the current windows are minimized.for eg. my application is full of sockets,when a system in a LAN contacts another system and is waiting for a confirmation it is left behind.The one who requested has to wait until the latter notices and responds.
So its a legal view I suppose.
Please reply as soon as possible.
[This message has been edited by netharam ram (edited September 06, 2001).]
Paul Stevens
Ranch Hand

Joined: May 17, 2001
Posts: 2823
If you look at the API for JDialog it shows the proper constuctor for this. You pass the the owner and true).
JDialog dialog = new JDialog(frame, true);
It could also be another JDialog as owner.
 
 
subject: creating Modal Dialog box.(urgent)
 
Threads others viewed
Adjusting the position of dialogue box when main window is restored.
forcing users to close popups
Please Help! How to create Modal Dialog Box in Servlet.
Flexible Dialog Box
Popup Frame
developer file tools