Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

runs perfectly only from my java\bin dir else errors...

 
Mike Frya
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So i have an applet and it runs with no problems from my java\bin\ directory. I put all the files (.java,.class,.html, .gif,.au) onto a floppy disk and tried to run the applet from the floppy disk. It only worked half way. The user interface was there (2 buttons, 2 textfields) and when a button was pressed music played as expected. But the textfield that showed time elapsed in seconds was not getting updated it just stays at zero. And the images do not appear randomly on the screen. This is a game where the user has to click the randomly appearing images 5 times before ten seconds is up. The java console says

any help would be appreciated!!Thanks
 
Rob Ross
Bartender
Posts: 2205
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The JVM is telling you it can't find a class file it needs, "Timer."
What is your directory structure for your Java files and resources? Do you have everything in one directory? If so, list all the .java files you have. Also, is the "Timer" class something you wrote, or something you're using from the Java API? It might be a classpath issue but it's hard to tell from what you have describeded.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic