Page 1 of 3 123 LastLast
Results 1 to 20 of 41
  1. #1
    gafa's Avatar
    gafa is offline Senior Member
    Join Date
    Jun 2010
    Posts
    107
    Rep Power
    0

    Exclamation Cannot run applet

    Hello

    I have a problem of the applet Select stock
    I put in params
    Stock: 3315
    Start date: 2008-07-31
    Time: 1000
    click Chart

    But get this error

    load: class ru/fmv/stock/ChartApplet.class not found.
    java.lang.ClassNotFoundException: ru.fmv.stock.ChartApplet.class
    at sun.plugin2.applet.Applet2ClassLoader.findClass(Un known Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unk nown Source)
    at sun.plugin2.applet.Plugin2Manager.createApplet(Unk nown Source)
    at sun.plugin2.applet.Plugin2Manager$AppletExecutionR unnable.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: open HTTP connection failed:http://www.findata.info/chart/ru/fmv...et/class.class
    at sun.plugin2.applet.Applet2ClassLoader.getBytes(Unk nown Source)
    at sun.plugin2.applet.Applet2ClassLoader.access$000(U nknown Source)
    at sun.plugin2.applet.Applet2ClassLoader$1.run(Unknow n Source)
    at java.security.AccessController.doPrivileged(Native Method)
    ... 7 more
    Exception: java.lang.ClassNotFoundException: ru.fmv.stock.ChartApplet.class
    What can it be? And Is it runs in your browsers? Maybe mine is not working...

  2. #2
    Sno's Avatar
    Sno
    Sno is offline Senior Member
    Join Date
    Apr 2010
    Posts
    195
    Rep Power
    5

    Default

    your errors clearly state your chartapplet class not found...
    and looks like because of your http connection.

    http://www.findata.info/chart/ru/fmv...et/class.class
    :rolleyes: ~ Sno ~ :rolleyes:
    '-~ B.S. Computer Science ~-'

  3. #3
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,371
    Blog Entries
    1
    Rep Power
    20

  4. #4
    gafa's Avatar
    gafa is offline Senior Member
    Join Date
    Jun 2010
    Posts
    107
    Rep Power
    0

    Default

    But they tell me it works fine in many browsers. they advice me to use the newest FF and IE 8 but my IE 8 doesn't run this applet :(

    I checked the connection and it is fine :confused:

    help

  5. #5
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,371
    Blog Entries
    1
    Rep Power
    20

  6. #6
    gafa's Avatar
    gafa is offline Senior Member
    Join Date
    Jun 2010
    Posts
    107
    Rep Power
    0

    Default

    watch the jar it contains the ru.fmv.stock.ChartApplet.class



    Help!!!

  7. #7
    gafa's Avatar
    gafa is offline Senior Member
    Join Date
    Jun 2010
    Posts
    107
    Rep Power
    0

    Default

    Quote Originally Posted by Eranga View Post
    Do you have latest FF in your PC? If so enable Java on the browser and run the code again.
    But they say it should work with IE 8 too :confused:

  8. #8
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,882
    Rep Power
    25

    Default

    I get the same error. Here's my Java Console
    Look at where I have commented <<<<<<<< NOTE.
    The browser is using the .class as the name of the class file.
    Java Plug-in 1.6.0_20
    Using JRE version 1.6.0_20-b02 Java HotSpot(TM) Client VM
    User home directory = C:\Documents and Settings\Owner

    ----------------------------------------------------
    c: clear console window
    f: finalize objects on finalization queue
    g: garbage collect
    h: display this help message
    l: dump classloader list
    m: print memory usage
    o: trigger logging
    q: hide console
    r: reload policy configuration
    s: dump system and deployment properties
    t: dump thread list
    v: dump thread stack
    x: clear classloader cache
    0-5: set trace level to <n>
    ----------------------------------------------------

    load: class ru/fmv/stock/ChartApplet.class not found.
    java.lang.ClassNotFoundException: ru.fmv.stock.ChartApplet.class
    at sun.plugin2.applet.Applet2ClassLoader.findClass(Un known Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unk nown Source)
    at sun.plugin2.applet.Plugin2Manager.createApplet(Unk nown Source)
    at sun.plugin2.applet.Plugin2Manager$AppletExecutionR unnable.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: open HTTP connection failed:http ://www.findata.info/chart/ru/fmv/stock/ChartApplet/class.class <<<<<<<< NOTE
    at sun.plugin2.applet.Applet2ClassLoader.getBytes(Unk nown Source)
    at sun.plugin2.applet.Applet2ClassLoader.access$000(U nknown Source)
    at sun.plugin2.applet.Applet2ClassLoader$1.run(Unknow n Source)
    at java.security.AccessController.doPrivileged(Native Method)
    ... 7 more
    Exception: java.lang.ClassNotFoundException: ru.fmv.stock.ChartApplet.class
    Here's part of the HTML for the <Applet page:
    appletClass = "ru/fmv/stock/TableApplet.class"


    var appletContainer = document.getElementById("appletContainer");
    appletContainer.innerHTML ='<APPLET id="stock" width="100%" height="100%"'+
    'code="'+appletClass+'"' +
    ' archive="jars/stock1.jar, jars/jcommon-1.0.16.jar, jars/jfreechart-1.0.13.jar, SuperCSV-1.52.jar, jars/spiffy-all-0.05.jar " '+
    ' > ' +
    ' <PARAM NAME="guid" VALUE="'+appletGuid+'"/> '+
    ' <PARAM NAME="service" VALUE="select_stock.php"/> '+
    ' <PARAM NAME="messageService" VALUE="select_message.php"/> '+
    ' <PARAM NAME="key" VALUE="1z2wqfsda"/> '+
    ' <PARAM NAME="stockCode" VALUE="'+stockCode+'"/> '+
    ' <PARAM NAME="startDate" VALUE="'+startDate+'"/> '+
    ' <PARAM NAME="resolution" VALUE="1"/> '+
    ' <PARAM NAME="time" VALUE="'+time+'"/> '+
    ' <PARAM NAME="limit" VALUE="400"/> '+
    ' <PARAM NAME="offset" VALUE="0"/> '+
    '</APPLET>';
    //alert( appletContainer.innerHTML);
    Last edited by Norm; 06-24-2010 at 09:34 PM.

  9. #9
    Webuser is offline Senior Member
    Join Date
    Dec 2008
    Posts
    526
    Rep Power
    0

    Default

    I just guessing but anyway...

    The class ru.fmv.stock.ChartApplet.class may be a "not complete" one or something...
    So it requires to download something from server using the http... the servlet part I guess? Could you provide us the inner code?
    If my answer helped you. Please click my "REP" button and add a comment
    Have a Good Java Coding :)

  10. #10
    Webuser is offline Senior Member
    Join Date
    Dec 2008
    Posts
    526
    Rep Power
    0

    Default

    Quote Originally Posted by Norm View Post
    I get the same error. Here's my Java Console
    Look at where I have commented <<<<<<<< NOTE.
    The browser is using the .class as the name of the class file.
    Yeah, Norm, I just thought that too ;)
    Some outer resource... The applet must be using a serialization... But why the author says they say it works fine :confused:

    @Norm
    Did you run the applet with your IE 8?

  11. #11
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,882
    Rep Power
    25

    Default

    When going to the site via a proxy server, this GET returns a 404:
    GET http://www.findata.info/chart/jars/stock1.jar HTTP/1.1

    HTTP/1.0 404 Not Found

    It finds the other 4 jar files.
    i'm using Mozilla

    I get the same class not found error in the Java Console with IE8

  12. #12
    Webuser is offline Senior Member
    Join Date
    Dec 2008
    Posts
    526
    Rep Power
    0

    Default

    Emm I just ref in some other way and got this

    http://www.findata.info/chart/jars/stock.jar

    So there must be missing the JAR as
    http://www.findata.info/chart/jars/stock1.jar
    Last edited by Webuser; 06-24-2010 at 10:23 PM.

  13. #13
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,371
    Blog Entries
    1
    Rep Power
    20

    Default

    Yea, it's able to find the JAR file on the first URL. But seems that main class is not define in manifest.

  14. #14
    Norm's Avatar
    Norm is offline Moderator
    Join Date
    Jun 2008
    Location
    Eastern Florida
    Posts
    17,882
    Rep Power
    25

    Default

    main class is not define in manifest
    Remember its an applet. The code= tag points to the starting class.

  15. #15
    Eranga's Avatar
    Eranga is offline Moderator
    Join Date
    Jul 2007
    Location
    Colombo, Sri Lanka
    Posts
    11,371
    Blog Entries
    1
    Rep Power
    20

    Default

    Yeah, that's true. But the Jar fail to load, may be that's not a valid applet. Or more main classes is available.

    Manifest-Version: 1.0
    Created-By: 1.6.0_06 (Sun Microsystems Inc.)
    No more details.

  16. #16
    Webuser is offline Senior Member
    Join Date
    Dec 2008
    Posts
    526
    Rep Power
    0

    Question

    Quote Originally Posted by Eranga View Post
    Yea, it's able to find the JAR file on the first URL. But seems that main class is not define in manifest.
    Eranga, did you succeed to download the jar as
    http://www.findata.info/chart/jars/stock1.jar

    cause I couldn't do this owing to my browser 404 :confused:
    If my answer helped you. Please click my "REP" button and add a comment
    Have a Good Java Coding :)

  17. #17
    gafa's Avatar
    gafa is offline Senior Member
    Join Date
    Jun 2010
    Posts
    107
    Rep Power
    0

    Default

    Quote Originally Posted by Webuser View Post
    Eranga, did you succeed to download the jar as
    http://www.findata.info/chart/jars/stock1.jar

    cause I couldn't do this owing to my browser 404 :confused:
    I couldn't download the jar at night but I could download it in the morning :confused:
    I started the applet but now got this

    load: class ru/fmv/stock/ChartApplet.class not found.
    java.lang.ClassNotFoundException: ru.fmv.stock.ChartApplet.class
    at sun.plugin2.applet.Applet2ClassLoader.findClass(Un known Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.plugin2.applet.Plugin2ClassLoader.loadCode(Unk nown Source)
    at sun.plugin2.applet.Plugin2Manager.createApplet(Unk nown Source)
    at sun.plugin2.applet.Plugin2Manager$AppletExecutionR unnable.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: open HTTP connection failed:http://www.findata.info/chart/ru/fmv...et/class.class
    at sun.plugin2.applet.Applet2ClassLoader.getBytes(Unk nown Source)
    at sun.plugin2.applet.Applet2ClassLoader.access$000(U nknown Source)
    at sun.plugin2.applet.Applet2ClassLoader$1.run(Unknow n Source)
    at java.security.AccessController.doPrivileged(Native Method)
    ... 7 more
    Exception: java.lang.ClassNotFoundException: ru.fmv.stock.ChartApplet.class
    What do you think?

  18. #18
    Webuser is offline Senior Member
    Join Date
    Dec 2008
    Posts
    526
    Rep Power
    0

    Default

    Quote Originally Posted by gafa View Post
    I couldn't download the jar at night but I could download it in the morning :confused:
    I started the applet but now got this



    What do you think?
    Emm...
    1) I think that applet reads a class.class file using the URL or something to download correctly. It must be its protection key or something...
    as you can see it is to read class.class and it is obvious by this exception

    Caused by: java.io.IOException: open HTTP connection failed:http://www.findata.info/chart/ru/fmv...et/class.class
    2) finds nothing and gets no bytes so we can see this exception

    at sun.plugin2.applet.Applet2ClassLoader.getBytes(Unk nown Source)
    3) then applet demands to use a native method and of course it should use a platform dependant code here but has no Privileges and we can see this exception as follows
    at java.security.AccessController.doPrivileged(Native Method)
    As I can see it is a test applet so could you provide us the ru.fmv.stock.ChartApplet.class problem code ?

    For some reason the class.class is not accessable :confused:
    I am not sure but maybe some stream cipher or something?
    If my answer helped you. Please click my "REP" button and add a comment
    Have a Good Java Coding :)

  19. #19
    Webuser is offline Senior Member
    Join Date
    Dec 2008
    Posts
    526
    Rep Power
    0

    Default

    @everybody
    Hey guys just let me know you succeed to download the class.class file cause I've got 404 only :(
    But I suppose it is a servlet... How you think?

  20. #20
    gafa's Avatar
    gafa is offline Senior Member
    Join Date
    Jun 2010
    Posts
    107
    Rep Power
    0

    Default

    Oh, pa

    I never even thought it is such a deep problem. But yummy I am interested much :D
    Last edited by gafa; 06-26-2010 at 05:52 AM.

Page 1 of 3 123 LastLast

Similar Threads

  1. Replies: 2
    Last Post: 09-29-2009, 04:33 PM
  2. Applet & sql
    By gan5016 in forum Java Applets
    Replies: 19
    Last Post: 08-27-2009, 05:28 PM
  3. more help with my applet
    By vouslavous in forum Java Applets
    Replies: 5
    Last Post: 04-25-2009, 03:05 AM
  4. Calling another applet on click of button in one applet
    By niteshwar.bhardwaj in forum Java 2D
    Replies: 1
    Last Post: 02-19-2009, 01:54 PM
  5. Replies: 4
    Last Post: 06-08-2007, 07:15 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
  •