It's not a secret anymore!*
The moose likes Applets and the fly likes JDialog with JApplet parent Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Applets
Bookmark "JDialog with JApplet parent" Watch "JDialog with JApplet parent" New topic
Author

JDialog with JApplet parent

Nigel Patching
Greenhorn

Joined: Jun 15, 2001
Posts: 7
Hi,
I want to have a JDialog appear in an JApplet, but have the JApplet as the parent frame to the JDialog.
Unfortunately JApplet is a super class to Frame / JFrame. I've tried casting it to Frame but (predictably) this gave me a runtime error.
Of course I could have no parent for the JDialog, but I would prefer the functionality you get when the JDialog has a parent.
Anyone got any ideas how I can do this?
Thanks,
NIgel
Manfred Leonhardt
Ranch Hand

Joined: Jan 09, 2001
Posts: 1492
Hi Nigel,
I would create a frame but don't make it visible and use as the parent of the dialog.

Regards,
Manfred.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JDialog with JApplet parent
 
Similar Threads
Parent Frames and Panel
Title icon on JDialogs
JDialog icon
JFrame / JDialog communication
JDialog Question