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 Creating modal in JInternalFrame 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 "Creating modal in JInternalFrame" Watch "Creating modal in JInternalFrame" New topic

Creating modal in JInternalFrame

Lilyana Saputra

Joined: Feb 03, 2006
Posts: 20
I have some JInternalFrame class
And i have 1 JFrame to show all JInternalFrame that i have using JDesktopPane.

My problem is...i want to show JInternalFrame (A) from other JInternalFrame (B)...And what i want is user can not use other JInternalFrame or other menus, except he close the JInternalFrame (A) ==> modal

But all JInternalFrame (B, etc) that called from JFrame (not modal) can be choose and actif if user select it!!!

How to solve this problem....
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15302

The solution is to use the appropriate components. JInternalFrames are not designed to be Dialogs. Thats what a JDialog or JOptionPane is for. Use them when you need modal windows.

GenRocket - Experts at Building Test Data
I agree. Here's the link:
subject: Creating modal in JInternalFrame
It's not a secret anymore!