The Daily Static
  The Daily Static
UF Archives
Register
UF Membership
Ad Free Site
Postcards
Community

Geekfinder
UFie Gear
Advertise on UF

Forum Rules
& FAQ


Username

Password


Create a New Account

 
 

Back to UserFriendly Strip Comments Index

Java help! The dreaded "NoClassDefFound" error! by jmaxsohmer 2006-10-26 20:50:24
Can anyone help me with this? I've already tried the usual "java -cp . <main class name>" trick... nothing. Doesn't work on the CS cluster (Gentoo) either.

I know my functional code is good because I build this with TDD and everything's green, but it's been so long since I've had to deal with this annoyance...

---

Exception in thread "main" java.lang.NoClassDefFoundError: KeyWordInContext (wro
ng name: edu/drexel/cs/serg/jmaxsohmer/academics/classes/bsse/se310/kwic/KeyWor
d
InContext)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)

---

Also, does anyone by any chance know how to turn this into an executable? For now I'll settle for getting it to run, but in the end it needs to be executable. I'm probably just going to put it in a Windows batch file, but does anyone know off the top of the head how to make it into a Windows EXE complete with JRE?

Thanks,

Jonathan
[ Reply ]
  just make a jar of it by Freakazoid2006-10-26 21:06:33
    Thanks, I'll try that. by jmaxsohmer2006-10-26 21:40:32
      Nope, still doesn't work. by jmaxsohmer2006-10-26 21:48:45
        a jar would still be best for convinence, though by Freakazoid2006-10-26 22:42:52
        Edit the Manifest file in the jar. by leonidus2006-10-27 00:04:30
  Given the wrong name error by ToLazyToThink2006-10-26 22:01:57

 

[Todays Cartoon Discussion] [News Index]

Come get yer ARS (Account Registration System) Source Code here!
All images, characters, content and text are copyrighted and trademarks of J.D. Frazer except where other ownership applies. Don't do bad things, we have lawyers.
UserFriendly.Org and its operators are not liable for comments or content posted by its visitors, and will cheerfully assist the lawful authorities in hunting down script-kiddies, spammers and other net scum. And if you're really bad, we'll call your mom. (We're not kidding, we've done it before.)