IntelliJ Java IDE
The moose likes Applets and the fly likes applet to applet communication Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Applets
Reply Bookmark "applet to applet communication" Watch "applet to applet communication" New topic
Author

applet to applet communication

raddikrishna kittur
Greenhorn

Joined: Dec 10, 2000
Posts: 7
hi,
Can you tell me how to call an applet from an applet .ie. if press a button on an applet it should open another applet.
Thanks in advance
KK
Sanjaya KasthuriArachchi
Greenhorn

Joined: Feb 06, 2001
Posts: 5
try this ..........
public void actionPerformed(ActionEvent A){
AppletContext appcon=getAppletContext();
appcon.showDocument("url of the page which contains the second applet","name of the frame");
}

Rohit Sharma
Greenhorn

Joined: Dec 28, 2000
Posts: 4
well! showDocument() works in browsers only. is there any method to open a new applet in appletviewer by pressing a button on one applet?
rohit
chinmay naidu
Greenhorn

Joined: Dec 02, 2000
Posts: 5
Can any body help on this ?I am also in the same prob...
Regards,
Cindy Glass
"The Hood"
Sheriff

Joined: Sep 29, 2000
Posts: 8521
An appletViewer is meant to be a "not fully functional browser". Just for testing basic applets. So the answer is - NO. You will have to test in a browser.


"JavaRanch, where the deer and the Certified play" - David O'Meara
sujata mehta
Greenhorn

Joined: Feb 21, 2001
Posts: 4
Hi!
is it possible that instead of pressing button i press some text in that applet & another applet gets opened?
Cindy Glass
"The Hood"
Sheriff

Joined: Sep 29, 2000
Posts: 8521
Yes, that would be a link. It would open a different HTML page with an applet on it.
sujata mehta
Greenhorn

Joined: Feb 21, 2001
Posts: 4
But how to give a link in applet if we r using drawString method to display the text which when pressed should open another page?
or some other method should b used to draw the text?
pls reply soooon.
Thanks
parag Joshi
Greenhorn

Joined: Feb 26, 2001
Posts: 2
try Using Mouse Listener to check out the Point that is clicked inside the text area. Then you will be able to get a click on the Text.
then the same procedure can be adopted.
 
 
subject: applet to applet communication
 
Threads others viewed
WA #1.....word association
Applet with a ServerSocket
Clock
Clock
Java program protection.
IntelliJ Java IDE