This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes Applets and the fly likes Can Applet start another applet in same DocumentBase ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Applets
Bookmark "Can Applet start another applet in same DocumentBase ?" Watch "Can Applet start another applet in same DocumentBase ?" New topic
Author

Can Applet start another applet in same DocumentBase ?

achana chan
Ranch Hand

Joined: Jul 29, 2002
Posts: 277
Hi.
I have an appletAA which does some verification.
If verified to true, then it can either
(1) start another .html file in the same getDocumentBase() and which <APPLET ... CODE=AppletBB... > tag will take me to another applet ; OR
(2) start AppletBB.class from within the appletAA.
I have the impression one cannot start an applet with another applet ???
What do I need to read up ???
UPDATE:
I think I had better clarify my question ( I confuse myself, but that's because JAVA is so complex ... ): :roll:
I understand codeBase = FQDN
If one applet is in Apache's document root, then can I invoke another applet in a sub-directory of the document root using getApplet() ?
UPDATE:
Only appletAA is running , appletBB is not running. BB is waiting to be called by AA.
Is there a way around this ???
UPDATE:
Seems the only way I can do this is to introduce a new class file AppletList which stores references to other applets in a hash table. I was hpoing that it would be just another sub-routine call.
Why can't I just import appletBB and take it from there ???
UPDATE
Well, the question is simply this : how to start appletBB from within appletAA ???
Inside the html, I can have

but this means both will be displayed and I don't want that.
I want one applet to be displayed and when a condition verifies to true, it will start up another applet.
In other languages and olden days, we call them sub-routines. All languages have sub-routines except JAVA.
UPDATE:
On the other hand, nothing in SUN's white-paper suggests that one applet cannot invoke another applet in the same getDocumentBase(), which adds to my frustration with JAVA
http://java.sun.com/sfaq/
[ November 24, 2002: Message edited by: achana chan ]

humanum errare est.
 
GeeCON Prague 2014
 
subject: Can Applet start another applet in same DocumentBase ?