English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

I want to design a Java applet that can start another Java program that will be used for socket based communication. I tried to make the communication with another applet but I’ve failed. So, I’ve got the idea of using a Java program for communication to be called from an applet. Is that possible. How? Any one can assist me?

Thanks in advance

2006-10-21 23:54:24 · 3 answers · asked by Mohamed AH 1 in Computers & Internet Programming & Design

3 answers

Have you tried RMI or Ajax? sorry Please put more details

2006-10-22 03:07:39 · answer #1 · answered by JavaClark 5 · 0 0

It is a little difficult to tell, but it sounds like you were originally trying to figure out how to have one applet call another applet. If so, here is how:

Each applet to be called needs to be named, e.g.


Then, the caller needs to get a reference to the callee:
Applet applet = getAppletContext().getApplet("register");
if (applet instanceof MyRegisterApplet){
MyRegisterApplet register = (MyRegisterApplet)applet;
//call the other applet's methods
Map map = register.getRegistry();
...

2006-10-24 09:34:53 · answer #2 · answered by vincentgl 5 · 0 0

You cannot do this without a signed/trusted applet. Applets are restricted to what ip they can communicate with - the one they origionated from.

2006-10-22 10:52:23 · answer #3 · answered by steelshadow 2 · 0 0

fedest.com, questions and answers