Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Java
  4. java.lang.ClassNotFoundException

java.lang.ClassNotFoundException

Scheduled Pinned Locked Moved Java
javahtmlgame-devsysadminhelp
11 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    arthur89kim
    wrote on last edited by
    #1

    I have created a Java game (183MB for .jar file) and can be played on local (offline) through .html and it works perfectly fine. However, once it is allocated into the server in my University, it does not run as expected and it projects the following exception:

    load: class wildwildwest.applet_selection_screen not found.
    java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen
    at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
    at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
    at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Exception: java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen

    What causes the above problem and what solution can be proposed to solve it? :) By the way, the .html code for the game is as followed is as following:

    <HTML>
    <HEAD>
    <TITLE>Wild Wild West</TITLE>
    </HEAD>
    <BODY bgcolor="#000000">

    <font color="#ffffff" face="Curlz MT">

    <center>
    <H3><HR WIDTH="100%">Wild Wild West<HR WIDTH="100%"></H3>

    <P>
    <APPLET CODE="wildwildwest.applet_selection_screen" archive="Wild Wild West.jar" width=800 height=600></APPLET>
    </P>

    </center>

    </font>
    </BODY>
    </HTML>

    N O J 3 Replies Last reply
    0
    • A arthur89kim

      I have created a Java game (183MB for .jar file) and can be played on local (offline) through .html and it works perfectly fine. However, once it is allocated into the server in my University, it does not run as expected and it projects the following exception:

      load: class wildwildwest.applet_selection_screen not found.
      java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen
      at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
      at java.lang.ClassLoader.loadClass(Unknown Source)
      at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
      at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
      at java.lang.Thread.run(Unknown Source)
      Exception: java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen

      What causes the above problem and what solution can be proposed to solve it? :) By the way, the .html code for the game is as followed is as following:

      <HTML>
      <HEAD>
      <TITLE>Wild Wild West</TITLE>
      </HEAD>
      <BODY bgcolor="#000000">

      <font color="#ffffff" face="Curlz MT">

      <center>
      <H3><HR WIDTH="100%">Wild Wild West<HR WIDTH="100%"></H3>

      <P>
      <APPLET CODE="wildwildwest.applet_selection_screen" archive="Wild Wild West.jar" width=800 height=600></APPLET>
      </P>

      </center>

      </font>
      </BODY>
      </HTML>

      N Offline
      N Offline
      Nagy Vilmos
      wrote on last edited by
      #2

      Check this link[^], it has most of the common problems for deploying an applet.


      Panic, Chaos, Destruction. My work here is done. Drink. Get drunk. Fall over - P O'H OK, I will win to day or my name isn't Ethel Crudacre! - DD Ethel Crudacre I cannot live by bread alone. Bacon and ketchup are needed as well. - Trollslayer Have a bit more patience with newbies. Of course some of them act dumb - they're often *students*, for heaven's sake - Terry Pratchett

      A 1 Reply Last reply
      0
      • N Nagy Vilmos

        Check this link[^], it has most of the common problems for deploying an applet.


        Panic, Chaos, Destruction. My work here is done. Drink. Get drunk. Fall over - P O'H OK, I will win to day or my name isn't Ethel Crudacre! - DD Ethel Crudacre I cannot live by bread alone. Bacon and ketchup are needed as well. - Trollslayer Have a bit more patience with newbies. Of course some of them act dumb - they're often *students*, for heaven's sake - Terry Pratchett

        A Offline
        A Offline
        arthur89kim
        wrote on last edited by
        #3

        Thanks for the suggestion but it doesn't seems to be able to solve the problem. There are others java games has been uploaded onto the same server but only the one I have is not able to work online while the rest can be loaded and played.

        N T 2 Replies Last reply
        0
        • A arthur89kim

          Thanks for the suggestion but it doesn't seems to be able to solve the problem. There are others java games has been uploaded onto the same server but only the one I have is not able to work online while the rest can be loaded and played.

          N Offline
          N Offline
          Nagy Vilmos
          wrote on last edited by
          #4

          If there are other applets running without a problem, I'd suggest you investigate the differences.


          Panic, Chaos, Destruction. My work here is done. Drink. Get drunk. Fall over - P O'H OK, I will win to day or my name isn't Ethel Crudacre! - DD Ethel Crudacre I cannot live by bread alone. Bacon and ketchup are needed as well. - Trollslayer Have a bit more patience with newbies. Of course some of them act dumb - they're often *students*, for heaven's sake - Terry Pratchett

          1 Reply Last reply
          0
          • A arthur89kim

            Thanks for the suggestion but it doesn't seems to be able to solve the problem. There are others java games has been uploaded onto the same server but only the one I have is not able to work online while the rest can be loaded and played.

            T Offline
            T Offline
            TorstenH
            wrote on last edited by
            #5

            check the libraries you're using. Might be a indirect reference, which causes the deployment not to find the jar and therefor not to work proper. Also check your build-Config, sometimes not all classes are marked to be added to the build.

            regards Torsten When I'm not working

            A J 2 Replies Last reply
            0
            • A arthur89kim

              I have created a Java game (183MB for .jar file) and can be played on local (offline) through .html and it works perfectly fine. However, once it is allocated into the server in my University, it does not run as expected and it projects the following exception:

              load: class wildwildwest.applet_selection_screen not found.
              java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen
              at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
              at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
              at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
              at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
              at java.lang.ClassLoader.loadClass(Unknown Source)
              at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
              at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
              at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
              at java.lang.Thread.run(Unknown Source)
              Exception: java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen

              What causes the above problem and what solution can be proposed to solve it? :) By the way, the .html code for the game is as followed is as following:

              <HTML>
              <HEAD>
              <TITLE>Wild Wild West</TITLE>
              </HEAD>
              <BODY bgcolor="#000000">

              <font color="#ffffff" face="Curlz MT">

              <center>
              <H3><HR WIDTH="100%">Wild Wild West<HR WIDTH="100%"></H3>

              <P>
              <APPLET CODE="wildwildwest.applet_selection_screen" archive="Wild Wild West.jar" width=800 height=600></APPLET>
              </P>

              </center>

              </font>
              </BODY>
              </HTML>

              O Offline
              O Offline
              Oscar0
              wrote on last edited by
              #6

              Maybe try changing your jar filename to no spaces.

              A 1 Reply Last reply
              0
              • A arthur89kim

                I have created a Java game (183MB for .jar file) and can be played on local (offline) through .html and it works perfectly fine. However, once it is allocated into the server in my University, it does not run as expected and it projects the following exception:

                load: class wildwildwest.applet_selection_screen not found.
                java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen
                at sun.plugin2.applet.Applet2ClassLoader.findClass(Unknown Source)
                at sun.plugin2.applet.Plugin2ClassLoader.loadClass0(Unknown Source)
                at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
                at sun.plugin2.applet.Plugin2ClassLoader.loadClass(Unknown Source)
                at java.lang.ClassLoader.loadClass(Unknown Source)
                at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unknown Source)
                at sun.plugin2.applet.Plugin2Manager.createApplet(Unknown Source)
                at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Unknown Source)
                at java.lang.Thread.run(Unknown Source)
                Exception: java.lang.ClassNotFoundException: wildwildwest.applet_selection_screen

                What causes the above problem and what solution can be proposed to solve it? :) By the way, the .html code for the game is as followed is as following:

                <HTML>
                <HEAD>
                <TITLE>Wild Wild West</TITLE>
                </HEAD>
                <BODY bgcolor="#000000">

                <font color="#ffffff" face="Curlz MT">

                <center>
                <H3><HR WIDTH="100%">Wild Wild West<HR WIDTH="100%"></H3>

                <P>
                <APPLET CODE="wildwildwest.applet_selection_screen" archive="Wild Wild West.jar" width=800 height=600></APPLET>
                </P>

                </center>

                </font>
                </BODY>
                </HTML>

                J Offline
                J Offline
                jschell
                wrote on last edited by
                #7

                arthur89kim wrote:

                What causes the above problem and what solution can be proposed to solve it?

                The class is not in the class path. The solution follows from that.

                arthur89kim wrote:

                I have created a Java game (183MB for .jar file) and can be played on local (offline) through .html and it works perfectly fine.

                Which means it is in the class path. Although it isn't clear what you mean by "through .html". I will note some oddities. 1. 183 meg is a really big jar 2. Class name doesn't follow standard naming. 3. Jar name shouldn't have spaces in it. What happens if you change, ONLY in the html, to XXX.jar? That should specifically fail because the jar doesn't exist. However if you get the same error then I would suppose that your jar is not being found on the server (thus it won't be in your client and not in the class path.) That is a guess though.

                A 1 Reply Last reply
                0
                • O Oscar0

                  Maybe try changing your jar filename to no spaces.

                  A Offline
                  A Offline
                  arthur89kim
                  wrote on last edited by
                  #8

                  thanks for the suggestion. I will try to solve it.

                  1 Reply Last reply
                  0
                  • J jschell

                    arthur89kim wrote:

                    What causes the above problem and what solution can be proposed to solve it?

                    The class is not in the class path. The solution follows from that.

                    arthur89kim wrote:

                    I have created a Java game (183MB for .jar file) and can be played on local (offline) through .html and it works perfectly fine.

                    Which means it is in the class path. Although it isn't clear what you mean by "through .html". I will note some oddities. 1. 183 meg is a really big jar 2. Class name doesn't follow standard naming. 3. Jar name shouldn't have spaces in it. What happens if you change, ONLY in the html, to XXX.jar? That should specifically fail because the jar doesn't exist. However if you get the same error then I would suppose that your jar is not being found on the server (thus it won't be in your client and not in the class path.) That is a guess though.

                    A Offline
                    A Offline
                    arthur89kim
                    wrote on last edited by
                    #9

                    Thanks for the suggestion. I will try the solution proposed. :)

                    1 Reply Last reply
                    0
                    • T TorstenH

                      check the libraries you're using. Might be a indirect reference, which causes the deployment not to find the jar and therefor not to work proper. Also check your build-Config, sometimes not all classes are marked to be added to the build.

                      regards Torsten When I'm not working

                      A Offline
                      A Offline
                      arthur89kim
                      wrote on last edited by
                      #10

                      Thanks for the information. I will try it out as soon as possible.

                      1 Reply Last reply
                      0
                      • T TorstenH

                        check the libraries you're using. Might be a indirect reference, which causes the deployment not to find the jar and therefor not to work proper. Also check your build-Config, sometimes not all classes are marked to be added to the build.

                        regards Torsten When I'm not working

                        J Offline
                        J Offline
                        jschell
                        wrote on last edited by
                        #11

                        TorstenH. wrote:

                        check the libraries you're using. Might be a indirect reference, which causes the deployment not to find the jar and therefor not to work proper.

                        Huh? Jars don't have dependencies - classes do. If the specified class is in the specified jar and the class has another class dependency which is not found then a different exception would be the result. Perhaps you meant something different?

                        1 Reply Last reply
                        0
                        Reply
                        • Reply as topic
                        Log in to reply
                        • Oldest to Newest
                        • Newest to Oldest
                        • Most Votes


                        • Login

                        • Don't have an account? Register

                        • Login or register to search.
                        • First post
                          Last post
                        0
                        • Categories
                        • Recent
                        • Tags
                        • Popular
                        • World
                        • Users
                        • Groups