How to pass parameters from an applet to a frame

V

Videotron

I would like to know how you pass parameters from an applet to a frame. I
know you can pass parameters to an applet such as ­<PARAM test=Variable> in
Html and simply do a getParameter(test); from an appalet. But how do you do
this in a frame? Or can java pass paramters from an applet that loads a
frame?
 
R

Roedy Green

I would like to know how you pass parameters from an applet to a frame. I
know you can pass parameters to an applet such as ?PARAM test=Variable> in
Html and simply do a getParameter(test); from an appalet. But how do you do
this in a frame? Or can java pass paramters from an applet that loads a
frame?

whether an applet loads in frame or not is immaterial to the way the
<APPLET tag works or how you get parameters.

Did I misunderstand your question?

see http://mindprod.com/jgloss/applet.html
 
C

Chris Smith

Videotron said:
I would like to know how you pass parameters from an applet to a frame. I
know you can pass parameters to an applet such as ­<PARAM test=Variable> in
Html and simply do a getParameter(test); from an appalet. But how do you do
this in a frame? Or can java pass paramters from an applet that loads a
frame?

Have you subclassed Frame? If so, then you just add a parameter to the
constructor. Voila, you're done! (If not, then do something similar
with whatever code you are writing.)

Forget that applet parameter stuff. Applet parameters are complicated
because you're communicating across different environments with an HTML
document. Passing a parameter to a frame is far easier.

--
www.designacourse.com
The Easiest Way To Train Anyone... Anywhere.

Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation
 
O

Oliver Wong

Videotron said:
I would like to know how you pass parameters from an applet to a frame. I
know you can pass parameters to an applet such as ­<PARAM test=Variable> in
Html and simply do a getParameter(test); from an appalet. But how do you do
this in a frame? Or can java pass paramters from an applet that loads a
frame?

It's unclear whether by "frame" you mean an HTML frame, or a Java Frame.

- Oliver
 
R

Richard Perreault

Could you please explain to me how to subclass a Frame? And how to add a
parameter to the constructor. Is it getParameter I am visual please explain.

Videotron said:
I would like to know how you pass parameters from an applet to a frame. I
know you can pass parameters to an applet such as ­<PARAM test=Variable>
in
Html and simply do a getParameter(test); from an appalet. But how do you
do
this in a frame? Or can java pass paramters from an applet that loads a
frame?

Have you subclassed Frame? If so, then you just add a parameter to the
constructor. Voila, you're done! (If not, then do something similar
with whatever code you are writing.)

Forget that applet parameter stuff. Applet parameters are complicated
because you're communicating across different environments with an HTML
document. Passing a parameter to a frame is far easier.

--
www.designacourse.com
The Easiest Way To Train Anyone... Anywhere.

Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation
 
A

andrewthommo

Richard said:
Could you please explain to me how to subclass a Frame?

import java.awt.*;

public MySubClassedFrame extends Frame {
.....
}
...And how to add a
parameter to the constructor.

import java.awt.*;

public MySubClassedFrame extends Frame {

public MySubClassedFrame(String myParameter) {
....
}
}

Note that these sorts of questions are best handled on
comp.lang.java.help.

HTH

Andrew T.
 
R

Richard Perreault

Problem was resolved in the comp.lang.java.help newsgroup. Thank you for
your help and support.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,013
Latest member
KatriceSwa

Latest Threads

Top