unable to execute a jar file - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

unable to execute a jar file

msakilamsakila Posts: 5Member
hi..
i was trying to create a Executable jar file.. after creating i was trying to run using the syntax java -jar Myjar.jar.. when i was doing this it shows the error message like "Exception in Thread main java.lang .NoClassDefFoundError" Even when i tried this for a jar file which contains the single class file also I'm gettin the same error..

i hav tried with all possible solutions which i known..
plz give me a solution..

Comments

  • tollitolli Posts: 44Member
    i've faced tis pblm with jdk 1.5...u need to change the path ....right click on "my computer" -> go advanced -> Environment Variables ->Edit-> do not erase anything, just add et the end of the line the path to the "bin" of java folder u downloaded to ur C: (example: ;jdk1.5in)

    another thing...u might have an old version...need to download a new one

    I got the jdk1.6 and it worked


  • msakilamsakila Posts: 5Member

    I'm usin jdk1.6.0 only.. i've set the path correctly eventhough am gettin the same error(java.lang.NoClassDefFounError).

    Even i've set with the new path for my jar directory alone.. No change.. plz help me out thru' this..
Sign In or Register to comment.