Your CLASSPATH environmental variable must be set to point at the root directory containing your class files. So, in this example, if your current working directory was /home/Ozer, then you need to set your CLASSPATH like this (assuming you are using the bash shell) export CLASSPATH=$CLASSPATH:/home/Ozer The above statement assumes you CLASSPATH has already been set to see your "classes.zip" file distributed with the JDK. If it has not been set (assuming you installed the JDK in /usr/local ), then your CLASSPATH would have to be set also include the path to classes.zip. It would be something like this: export CLASSPATH=/usr/local/JDK/lib:/home/Ozer Type in both of these lines (substituting the paths on your computer ) from the Shell prompt. Hope this helps ( I believe it should ) Jason Hofffman ([EMAIL PROTECTED]) Ozer Irfan wrote: > I have this message > > Exception in thread "main' java.lang.NoClassDefFoundError > > when I run > > java test1 > > With javac I don't have problems > > this is the program > > import java.io.* ; > > public class test1 { > public static void main(String args []) { > > System.out.println("Hello"); > } > } > > Thanks
begin:vcard n:Hoffman;Jason tel;pager:972-568-1713 x-mozilla-html:FALSE org:Software Concepts / MTM Consulting adr:version:2.1;;;Dallas;TX;; version:2.1 email;internet:[EMAIL PROTECTED] title:Programmer/Instructor note;quoted-printable:SUN Certified JAVA 1.1 Programmer.=0D=0AC programmer, UNIX instructor,=0D=0Aand JAVA instructor.=0D=0A fn:Jason Hoffman end:vcard