The Ghost Applet

I am working with an Applet using plug-in 1.4 and having a strange problem.
When the applet is reloaded using IE the 2 JTabbedPane JPanels duplicate
themselves. It continues with each refresh/reload.
I have tried "this.getContentPane().removeAll();"
in the stop and destroy methods, but it had no effect.
I've only seen one other posting like this in this Forum but no solution
was posted.
Can someone please explain this????

For those of you who may have the same lame-brained problem, I figured it out.
Apparently I had created a few static elements outside of the initialization routine
up where data is declared.
When I move the creation of these references into the init() method they got cleaned-up
each time.
Doh!

Similar Messages

  • Multiple instances of the same applet loaded causes problem

    I have a java applet that has several classes in the project. The applet has a JTable a JButton and a JLabel control. The applet is displayed within an HTML page. The problem is that if a user opens the same html page more than once with the applet in it, only the last applet loaded receives the screen updates.
    For example in one senario. I have an error message that displays in the Label control once they click on the button.
    The user opens the html page and the applet is loaded (window 1). The user then opens the same html page again (window 2) with window 1 still open. If the user clicks on the Button in window 1, the error message is displayed in the window 2 applet.
    Originally I had some static variables. Thinking it was being used globally by the JVM so I removed all of them and it still happens. I have tried using both the Applet and Object tag. But it still happens.
    Has anyone experienced this before? Any suggestions on how to make the applet update the instance that recieved the events and not just the last one that was loaded?

    You need to look at applet classloader issues. If applets have the same archive list and come from the same codebase, they have the same classloader. A class is namespaced by it's class + classloader. Any statics in a class with a classloader will be shared. If you instead make it such that your applets have unique classloaders (which you can't change for unsigned applets by yourself) by changing the codebase, that would be one solution.
    For other solutions, I recommend searching the forum. This issue comes up a lot.

  • Problem:Multiple instances of the same applet on a webpage...

    I have an applet which connects to a server to read an XML-file.
    I use Doucument to parse the XML-file like this:
    String xmlurl="http://www.somesite.com/somexmlpage.php";
    Document d =DocumentBuilderFactory.newInstance().newDocumentBuilder().parse(xmlurl);
    (...read the XML-file...)
    This works fine.
    However, I need multiple instances of the same applet running at the same time on the same webpage.
    Now, with multiple applets running at the same time the parsing no loger works. If one applet is doing some parsing and a taskswitch takes place to let another applet run, the applet which is interrupted is not able to continue the parsing as it looses its "incoming data" when another applet reads from the server.
    How can different applets affect each other like this?
    And how can I fix the problem?
    Thanks in advance for any help!!

    However, I need multiple instances of the same applet running at the same time on the same webpage.
    Why? But okay.Because the the different applets show information about different items.
    Now, with multiple applets running at the same time the parsing no loger works. If one applet is doing some parsing and a
    taskswitch takes place to let another applet run, the applet which is interrupted is not able to continue the
    parsing as it looses its "incoming data" when another applet reads from the server.
    How did you determine that's what's happening?By printing out debuginformation.
    Each applet prints out a message (System.out.println) when it creates an instance of Document (ie. connects to the server) and the applet also prints out XML-information as the XML-file is processed.
    But, actually, I was a bit quick in my first post; The applet doesen't neccesarily loose its "incoming data", but the parser looses the data it is parsing. I can download the data from the server first, and then start parsing it. If a taskswitch happens while one applet is parsing, it looses its data, even if the data is allready downloaded.
    I see this since I see another applet making a printout, and when first applet starts again, the parser has lost track of its data.
    It works fine if only one applet is running. And everything is fine until the next applets starts; I can see this from the printout.
    Again, the appet prints out data as it parses the document. I see the next applet starting to work, and when the first one continues parsing again the printout shows that data is no longer there. It happens everytime the runtime switches to another applet, and it never happens if just one applet is running.
    Googeling a little tells me that DocumentBuilder.parse() isn't thread-safe, but this shouldn't have anything to do with it, should it?
    Each applet is a separate process, and not different threads in the same process, aren't they? (Not sure how the runtime treats multiple applets...)And secondly, the applets create their own instance of Document anyways.

  • How do you set a default Home Page in the Safari Applet?

    How do you set a default Home Page in the Safari Applet?

    How do you set a default Home Page in the Safari Applet?

  • How do I clear all of the java applets that have been downloaded?

    I migrated firefox and other applications to my new mac so that I would not to reenter all of my passwords saved by firefox. However, it appears that the java applets were also transfered and one of these applets does not work with the new intel mac. I was able to get the same applet to work in safari, and I was able to delete the applet from safari as well, but was unable to do so in firefox.
    So, how do I clear all of the previously downloaded applets, or even better, just the one I want to? Clearing all of the recent history didn't work.
    Here is the site:
    http://www.mdbg.net/chindict/chindict.php
    == This happened ==
    A few times a week

    I did that already, and it cleared the applets for Safari, but not for Firefox.

  • Setting the: signed.applets.codebase_principal_support to true is not working ( keeps asking to set it to true)

    i've Set the Boolean string to true but when i try to copy paste in firefox it just gives me the message again
    ( you need to set the signed.applets.codebase_principal_support to true )
    Is this a know bug ?
    thanks.

    Try this extension - Allow Clipboard Helper: <br />
    https://addons.mozilla.org/en-US/firefox/addon/852

  • Problem in compiling the sample applet

    hello: im installed jdk 1.2.2 now i wanna folow the instruction written in the
    PDF document.i did everything as it is but when i arrived to the step
    "compiling the sample applet" i issue the command
    " javac -g src/com/sun/javacard/samples/helloWorld/*.java"
    but it doesn't work it give me a message that the command is not known.
    i changed the directory where i issue the command from to c:\jdk1.1.6\bin
    then he find it but i have an other problem is that he makes to error:
    "package.javacard.framework not found in the import"
    "import javacard.framework.*"
    the second errer :
    "superclass com.sun.javacard.samples.HelloWorld.applet of class com.sun.javacard.samples.HelloWorld.HelloWorld not found"
    "public class HelloWorld extends applet"
    i don't know why it doesn't work eventhought i folowed the steps as they are written .
    can some one help me because i can"t pass to the next step if i couldn't compile those files.
    thank you very much

    See http://forum.java.sun.com/thread.jsp?forum=7&thread=203737

  • Where can I set the window dimensions for the "Java Applet window"?

    Hi,
    When I run a form on the web, the Java Applet is loaded and the form appear in the window. But "base window" have gived dimensions indifferent what dimensions has the window of the form which I run.
    So, where can I set the dimensions of the "core window" which is behind the MDI window of the application?
    Thanks in advance,
    Eugen

    Eugen,
    in formsweb.cfg you will find parameters "width" and "height". You can set absolute values in pixels or "relative" in percent.
    width=800
    height=600
    or
    width=100%
    height=100%
    Gerald Krieger

  • How do i get the java applet to stop appearing on the dock?

    how do i get the java applet to stop appearing on the dock? it seems to do this for pop-up windows.  also, the text on the popup window is different, how can I change that to normal?   this all started when i loaded MAC OS X 10.6.8

    You could try to block popup windows.
    Safari / Preferences / Security
    Also, go to Safari / Preferences / Extensions and clean out everything there.

  • How to maximize the java applet?

    Dear all,
    I have an application & when ever i run it, the java applet never comes in a maximum size. so is there a way to make it run in a maximum size?
    best regards,
    Ashraf

    so but htese two lines in the new_form_instancse trigger
    SET_WINDOW_PROPERTY(FORMS_MDI_WINDOW,WINDOW_STATE,MAXIMIZE);
              SET_WINDOW_PROPERTY('WINDOW1',WINDOW_STATE,MAXIMIZE);
    good luck

  • Adding keylistener to the entire applet

    How can I addKeyListener(this) to the entire applet frame? I know in applications you name the frame and everything then can just add it to whatever you named it, but applets make the frame on their own. So what do I tell to addkeylistener to?

    lol thanks
    I just put
    addKeyListener(this);whatever.. thanks :)

  • Has there been any helpful remedy for the ghost typing issue?

    Has there been any helpful remedy for the ghost typing issue? Where the ipad starts typing on its own and screens moving around the screen?
    I have had the ipad 1 for a while- and it started about 5 months ago. Anything other than shutting down and leaving alone for hours work?

    Yeah, well if you read that whole thread you will see lots of posts identifying it as a hardware problem:
    I'm the original poster on this thread. I ended up taking my iPad back to the Apple Store. They ran some diagnostics, and found that my RAM was almost maxed out, which didn't really make sense. It indicated a faulty processor, so they gave me a new iPad. I took it home, synched, and it only took about 45 minutes to synch 30 gigs of data. My original iPad took about 5 hours to synch for the first time. Clearly there was a problem with the processor in the first one, but I didn't realize it at first, as it took several weeks before it started exhibiting the erratic screen behavior. Hope this helps anyone else who might experience this down the line.
    -merenvov
    So i went to my apple store... which was PACKED. Found a manager and explained my problem. Without any question, they simply replaced it. Awesome!
    -duncanwilcox
    I have the same problem, and I found out what's wrong, it's not the software - restart, restore and FW upgrade will not help, it's definitely hardware. The best option is to replace your iPad assuming you have an apple store nearby…
    -DarkDwarf
    Just get your iPad replaced. It has a hardware problem.

  • Extending the transactionsigner applet to prompt for user's pin

    Has anyone used the transactionsigner applet in IDM to capture the user's pin associated with the smart card? The sample provider class in the REF kit hints at the need to prompt for a pin but there doesn't seem to be a built in mechanism of the applet to prompt the user.
    Am I missing something?
    Thanks,
    Scott

    Best solution is to create an account that is exclusive to binding machines.  By doing this, you can embed the user name and password in the script.  Heck, you can post it on your website.  If the account is configured properly, it will only be able to create machine records in a defined container.  If you are mixing Macs and PCs in your AD domain, I also recommend creating an isolated container for your Mac records.  Now, the account has even less access rights as you can make it so it only has rights to the Mac container.
    Otherwise, ARD does not prompt.  You can play around with an expect script but the reality is that you are still embedding the credentials in the script so it really does not achieve what you want.  ARD is not an interactive shell scripting tool.  It is more a fire and forget.
    Reid
    Apple Consultants Network
    Apple Professional Services
    Author "Mavericks Server – Foundation Services" :: Exclusively available in Apple's iBooks Store

  • How to get hold of the JavaFX applet in some java code called from it

    I have a scenario where I am trying to reuse some java libraries that existed before and used the Applet API. In order to give a new UI to these APIs I am redesigning the front end using JavaFX. I can create instances of java classes from these old libraries. Methods on these old classes take java.applet.Applet as an argument.
    When the JavaFX applet is deployed as an applet, how can one get hold of the corresponding Applet object?
    Thanks in advance.

    When run as an applet, FX.getArgument("javafx.applet") will return the JApplet instance.

  • If the whole applet window stays visible, can repainting still occur?

    Hello, if a user scrolls a browser up and down, during which process the whole applet window stays visible (just moves up and down in the browser window), can painting code inside the applet still be called?? As far as I understand painting, no, but please if an expert could confirm I'd appreciate.
    The problem I am having, is in the above situation, my applet shows artefacts, like lines repeating twice, as if my painting code were messed up. But the applet is not computing an image, it is not computing anything, just displaying an image, and the only thing that is happening is that I scroll the browser so it moves up and down (staying visible all the time). Am I right to assume this cannot be a problem in my applet code?
    No SSCCE since I don't think this is my code. Thank you for any opinions. Mark

    the only thing that is happening is that I scroll the browser so it moves up and down (staying visible all the time). So your saying the problem is not with your code but its with the scrolling of the applet?
    if you could just bring your considerable expertise to bear and just write a simple "yes", "no", "maybeI did give you my answer. I don't believe anything is a bug, unless you can post code that demonstrates it.
    And if you code is 30K, what do you think the chances are the problem is in one of those lines of code.
    And no, I have absolutely no idea what it could be.

Maybe you are looking for