View Single Post
  #1 (permalink)  
Old 08-06-2007, 06:31 AM
baltimore baltimore is offline
Member
 
Join Date: Jul 2007
Posts: 40
baltimore is on a distinguished road
Exception in thread "main" java.lang.NoClassDefFoundError
Hi, for my class lab assignment I had to copy files from one directory and put them in my /Java/Lab4/inventory/ directory, I can compile my Inventory.java file by typing

Code:
javac -classpath $HOME/Java/Lab4 Inventory.java
that then creates Inventory.class file in that same directory... and i want to run it; that's where the problem is; to run it I'm typing

Code:
java -classpath $HOME/Java/Lab4 Inventory.class
I've also tried
java Inventory.class

The error I'm getting is

Code:
Exception in thread "main" java.lang.NoClassDefFoundError: /users/klepeis/Java/Lab4
Thanks.
Reply With Quote
Sponsored Links