>I am having problem over and over again using it.
>This time I cant even figure out whats the problem.
[quoted text clipped - 3 lines]
>press the button to execute the file nothing is happening. Its not
>executing.
yeah p1 works as it should have been after modifications, I tried
running it by itself.
I get the following output on reading the errorstream:
Exception in thread "main" java.lang.NoClassDefFoundError: while
resolving class: hinuri1
at java.lang.VMClassLoader.resolveClass(java.lang.Class)
(/usr/lib64/libgcj.so.5.0.0)
at java.lang.Class.initializeClass() (/usr/lib64/libgcj.so.5.0.0)
at java.lang.Class.forName(java.lang.String, boolean,
java.lang.ClassLoader) (/usr/lib64/libgcj.so.5.0.0)
at gnu.gcj.runtime.FirstThread.run() (/usr/lib64/libgcj.so.5.0.0)
at _Jv_ThreadRun(java.lang.Thread) (/usr/lib64/libgcj.so.5.0.0)
at _Jv_RunMain(java.lang.Class, byte const, int, byte const,
boolean) (/usr/lib64/libgcj.so.5.0.0)
at __gcj_personality_v0
(/misc/fs11/bt2003/rohitg/InputPanel/java.home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre)
at __libc_start_main (/lib64/tls/libc-2.3.3.so)
at _Jv_RegisterClasses
(/misc/fs11/bt2003/rohitg/InputPanel/java.home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre)
Caused by: java.lang.ClassNotFoundException: java.lang.StringBuilder
not found in [file:/usr/share/java/libgcj-3.4.2.jar, file:./, core:/]
at java.net.URLClassLoader.findClass(java.lang.String)
(/usr/lib64/libgcj.so.5.0.0)
at gnu.gcj.runtime.VMClassLoader.findClass(java.lang.String)
(/usr/lib64/libgcj.so.5.0.0)
at java.lang.ClassLoader.loadClass(java.lang.String, boolean)
(/usr/lib64/libgcj.so.5.0.0)
at _Jv_FindClass(_Jv_Utf8Const, java.lang.ClassLoader)
(/usr/lib64/libgcj.so.5.0.0)
at java.lang.Class.forName(java.lang.String, boolean,
java.lang.ClassLoader) (/usr/lib64/libgcj.so.5.0.0)
at _Jv_BytecodeVerifier.verify_instructions_0()
(/usr/lib64/libgcj.so.5.0.0)
at _Jv_VerifyMethod(_Jv_InterpMethod) (/usr/lib64/libgcj.so.5.0.0)
at _Jv_PrepareClass(java.lang.Class) (/usr/lib64/libgcj.so.5.0.0)
at _Jv_WaitForState(java.lang.Class, int)
(/usr/lib64/libgcj.so.5.0.0)
at java.lang.VMClassLoader.linkClass0(java.lang.Class)
(/usr/lib64/libgcj.so.5.0.0)
at java.lang.VMClassLoader.resolveClass(java.lang.Class)
(/usr/lib64/libgcj.so.5.0.0)
...8 more
hinuri1 is p1.
I have both the files( java and class file) placed in the correct
location, so why is it showing NoClassDefFoundError...
I printed out the execute string and it is fine, as it should be...
Rohit Gupta
Rohit Gupta - 25 Jun 2005 14:26 GMT
just to add( maybe that would help).....I had made the whole thing in
netbeans, and now when I am running the same thing on windows its
working perfectly fine. I am more perplexed now....where does the
problem lie and how to get rid of it......why isnt it working on linux.
It was working on both the platforms before the modification.
plz help, I need to get it working on both the platforms....
Rohit Gupta
ps: I had copied the modified project in windows( on a different comp.)
and ran it, it wasnt there previously.
Johan Poppe - 25 Jun 2005 16:52 GMT
Rohit Gupta wrote:
>yeah p1 works as it should have been after modifications, I tried
>running it by itself.
>I get the following output on reading the errorstream:
>
>Exception in thread "main" java.lang.NoClassDefFoundError: while
>resolving class: hinuri1
...
>Caused by: java.lang.ClassNotFoundException: java.lang.StringBuilder
>not found in [file:/usr/share/java/libgcj-3.4.2.jar, file:./, core:/]
> at java.net.URLClassLoader.findClass(java.lang.String)
...
This looks like a classpath problem to me. It seems that you get
different settings for the JVM when you run it with exec from another
JVM instance than when you run from the command line. I am not sure
whether it's the class 'hinuri1' or 'java.lang.StringBuilder' it can't
find, though. Note that StringBuilder is a new class in java2 SE 5.0,
it could be that for some reason you end up with an older jvm when you
exec. (You could try to exec "java -version")
>hinuri1 is p1.
By the way, it's a very common convention in Java to capitalize class
names, i.e. the class should be called Hinuri1 and not hinuri1.

Signature
Johan Utne Poppe
Rohit Gupta - 25 Jun 2005 20:40 GMT
It was working fine before...means I just made trivial changes in the
p1 file, that of changing the file name which it produced as output and
then its not working. Before that it was fine. The java version which I
am using is jdk1.5 which comes with netbeans4.0. When I am using it on
a diff machine with identical settings its working. The problem caused
hardly seem to be due to the changes made because that would not affect
the execution of the program and else wise also its getting executed on
the terminal. Is it that the some previous classes present are not
getting modified after making the changes so its causing some sort of
conflict or so, I dont know what is happening...feeling helpless now.
Roedy Green - 26 Jun 2005 11:11 GMT
>It was working fine before...means I just made trivial changes in the
>p1 file, that of changing the file name which it produced as output and
>then its not working. Before that it was fine.
See http://mindprod.com/jgloss/dependencies.html
Make sure every class you need is in the jar.

Signature
Bush crime family lost/embezzled $3 trillion from Pentagon.
Complicit Bush-friendly media keeps mum. Rumsfeld confesses on video.
http://www.infowars.com/articles/us/mckinney_grills_rumsfeld.htm
Canadian Mind Products, Roedy Green.
See http://mindprod.com/iraq.html photos of Bush's war crimes
Rohit Gupta - 26 Jun 2005 11:37 GMT
Ya, every class is present in the jar. I checked it.
I had previously used JApplets but because of the security problem I
had to resort to JFrames.
Roedy Green - 26 Jun 2005 11:11 GMT
> java.lang.NoClassDefFoundError:
see
http://mindprod.com/jgloss/runerrormessages.html#NOCLASSDEFFOUNDERROR

Signature
Bush crime family lost/embezzled $3 trillion from Pentagon.
Complicit Bush-friendly media keeps mum. Rumsfeld confesses on video.
http://www.infowars.com/articles/us/mckinney_grills_rumsfeld.htm
Canadian Mind Products, Roedy Green.
See http://mindprod.com/iraq.html photos of Bush's war crimes