Article View: borland.public.jbuilder.java.language
Article #19294How to access parent Frame from Applet?
From: Alex Humphreys
Date: Wed, 18 Feb 1998 00:00
Date: Wed, 18 Feb 1998 00:00
18 lines
1059 bytes
1059 bytes
I have an applet inside a frame inside an application. From the Applet,
I am trying to load a dialog box, which requires a reference to the
frame. here's how I'm trying to do it:
my_Dialog my_Dialog = new my_Dialog(this.getParent());
my_Dialog.show();
But this gives an error: "Error (598) constructor
my_Dialog(java.awt.Container) not found in class rte.my_Dialog."
Why is getParent() returning the Container and not the Frame, as I
thought it should (this is the phrase that the docs told me to use)?
How can i create this Dialog box?
Thanks.
--Alex
Technical Details
Message-ID:
<34EB12A6.ED625106@sema4.com>Path:
arc1-ca.pugleaf.net!unknown!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: f74b3,518e42f1a7b03a9b,start X-Google-Attributes: gidf74b3,public From: Alex Humphreys <ahumphreys@sema4.com> Subject: How to access parent Frame from Applet? Date: 1998/02/18 Message-ID: <34EB12A6.ED625106@sema4.com> X-Deja-AN: 326270782 Content-Transfer-Encoding: 7bit Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Organization: None Newsgroups: borland.public.jbuilder.java.language