Jump to content

  • Log In with Google      Sign In   
  • Create Account

Awesome job so far everyone! Please give us your feedback on how our article efforts are going. We still need more finished articles for our May contest theme: Remake the Classics

[java] applet to applet communication


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
3 replies to this topic

#1 ao   Members   -  Reputation: 122

Like
Likes
Like

Posted 19 December 2000 - 12:58 PM

I have been trying to come up with ways that I can have two applets running under the same web browser, but different pages communicate. 1 - Using getAppletContext().getApplet( ... ) 2 - Opening some sockets and sending data back and forth 3 - Using java-script as the messanger, requires some LiveConnect or something like that plugin. First off, #1 is a no no, because the java specs say that you can''t have two java apps communicating if they exist on different html pages ( mine do ). Some browsers support it, but not all. #2 - no probs with this yet #3 - I don''t want the user to have to download a plugin... Have I missed any other ways, The two java applets are different applets, so I can''t create any Static variables and communicate that way either. ao

Ad:

#2 loserkid   Members   -  Reputation: 122

Like
Likes
Like

Posted 19 December 2000 - 02:15 PM

Here is a tut on that subject at JavaWorld.

Cheers, JP.


==============================================
I feel like a kid in some kind of store...
==============================================
www.thejpsystem.com

#3 ao   Members   -  Reputation: 122

Like
Likes
Like

Posted 19 December 2000 - 04:33 PM

Thanks for the link. I''m a little stuck though. I don''t know if you have tried out the code, but somethings not working right. I don''t see the result of changing the static variable throughout all the applets? I made sure the applets were all in the same codebase and all that... So I''m a little stuck on that.

Anyone else have any luck with this stuff?

ao

#4 ao   Members   -  Reputation: 122

Like
Likes
Like

Posted 19 December 2000 - 05:32 PM

Hmmm, ok after a little tinkering it appears as though it works if the class files aren't all packed up into a jar or cab file. Well that sucks, because I need to do some networking stuff and thus require a signed cab or jar file. Boy oh boy, why does java always find a way to really really piss me off.

Another thing that pisses me off is that I hear you should be able to open a socket to the server from which the applet originated without requiring permission from the user. This does not seem to work for me either, If I could solve that problem then I would just leave them as classes and I could use the static varibables to communicate. arrrrrrrrrrrrrrr!!!!!

ao

Edited by - ao on December 19, 2000 12:33:28 AM




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS