Computer Science Canada

How to get eclipse working?

Author:  Kameboy [ Tue Apr 12, 2011 7:19 pm ]
Post subject:  How to get eclipse working?

I get these problems everytime i uninstalled and reinstalled jre 6 to see if that would fix it but it doesn't.

java.lang.NoClassDefFoundError: Helloworld
Caused by: java.lang.ClassNotFoundException: Helloworld
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)
Exception in thread "main"

any suggestion on how to get this to work properly

Author:  Tony [ Tue Apr 12, 2011 7:22 pm ]
Post subject:  RE:How to get eclipse working?

Quote:

java.lang.No Class Def Found Error: Helloworld

How are you trying to compile + execute your code?

Author:  Kameboy [ Sat Apr 16, 2011 5:45 pm ]
Post subject:  Re: How to get eclipse working?

Yeah i tried running a simple hello world so see if i set it up properly

Author:  Zren [ Sat Apr 16, 2011 7:59 pm ]
Post subject:  RE:How to get eclipse working?

The filename of the class must be the same as the name of the class. This is case sensitive. It must also be a public class.

Eg:

Filename: Helloworld.java

public class Helloworld {
public static void main(String[] args) {}
}

Author:  Kameboy [ Wed Apr 20, 2011 6:04 pm ]
Post subject:  Re: How to get eclipse working?

I tried what you said it still not working.

Author:  chrisbrown [ Wed Apr 20, 2011 6:36 pm ]
Post subject:  Re: How to get eclipse working?

Kameboy @ Tue Apr 12, 2011 7:19 pm wrote:
I get these problems everytime i uninstalled and reinstalled jre 6 to see if that would fix it but it doesn't.

You do have the JDK installed, right?

Author:  Kameboy [ Thu Apr 21, 2011 5:57 pm ]
Post subject:  Re: How to get eclipse working?

What would be a good JDK to install i download the JDK from this website
http://www.oracle.com/technetwork/java/javase/downloads/index.html


: