Updating an applet


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 8 of 8

Thread: Updating an applet

Hybrid View

  1. #1
    Join Date
    Oct 2005
    Posts
    36

    Updating an applet

    Hello,

    I'm having this problem: when I run an applet, and subsequently change something from the code (ex. changing the size of a TextArea), then I recompile, and load the .html file, but the TextArea doesn't update to its new size. This happens also for other small things like changing a String etc....

    Anyone knows what could be the problem?

  2. #2
    Join Date
    Dec 2005
    Location
    New Jersey
    Posts
    290
    Are you uploading the new .jar or .class file?

  3. #3
    Join Date
    Oct 2005
    Posts
    36
    I edit the program in JCreator, then re-compile the program. Isn't the .class file updated that way?

  4. #4
    Join Date
    Oct 2005
    Posts
    36
    I'm noticing that after some time, the applet updates accordingly, however when I re-open it, it goes back to the previous version, and so on..... strange problem. I don't know if the fact that I only have the init() method has to do with this. (I don't have the other methods start(), paint(), stop(), destroy(), update()).

  5. #5
    Join Date
    Dec 2005
    Location
    New Jersey
    Posts
    290
    Wait... is this applet on a website and you are trying to re-upload it? Or is the actual program just not updating when running it through appletviewer?

  6. #6
    Join Date
    Oct 2005
    Posts
    36
    No it's not an a website, I'm running it through the usual html code: <HTML><BODY>
    <APPLET CODE=abc.class WIDTH=300 HEIGHT=200></APPLET>
    </BODY></HTML>

    When I re-run the html file and open the applet with Internet Explorer with the amended version, the applet doesn't update...

  7. #7
    Join Date
    Oct 2004
    Posts
    311
    Try <crtl>+<F5> in your browser.
    This behavious is probalby due to the fact that the applet is stored in the cache of your browser and the above key-comba tells your browser to refresh the page and ignore the fact that any part of the page might be in cache already.

  8. #8
    Join Date
    Oct 2005
    Posts
    36
    Thanks guys, I have created a new file and now the applet updates accordingly.

Similar Threads

  1. JavaMail applet problem
    By Tataroz T. in forum Java
    Replies: 1
    Last Post: 10-20-2005, 07:19 AM
  2. Bouncing Ball Applet
    By nescafe in forum Java
    Replies: 1
    Last Post: 10-07-2005, 09:51 AM
  3. Replies: 3
    Last Post: 08-23-2001, 12:01 PM
  4. Help in Deploying Applet
    By Bill in forum Java
    Replies: 0
    Last Post: 02-27-2001, 11:42 PM
  5. Replies: 0
    Last Post: 03-28-2000, 02:52 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center