Skip to main content



      Home
Home » Newcomers » Newcomers » error message on setup
error message on setup [message #179051] Wed, 08 November 2006 18:48 Go to next message
Eclipse UserFriend
Originally posted by: alexis_maubourguet.hotmail.com

Hello everybody,

I have downloaded Eclipse SDK but I can't make it work. When I execute
Eclipse.exe, I get an error message saying:

A JRE or JDK must be available in order to run eclipse. No Java virtual
machine was found after searching the following location:
C:\programmes\eclipse\jre\bin\javaw.exe
"javaw.exe in your current PATH"

I have a file called jre that I have put in my Eclipse file but it does
not contain an executable called javaw.exe...

What can I do?

Thanks for your help!
Alexis
Re: error message on setup [message #179136 is a reply to message #179051] Wed, 08 November 2006 21:11 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wayne.beaton._NOSPAM_eclipse.org

Alexis wrote:
> Hello everybody,
>
> I have downloaded Eclipse SDK but I can't make it work. When I execute
> Eclipse.exe, I get an error message saying:
>
> A JRE or JDK must be available in order to run eclipse. No Java virtual
> machine was found after searching the following location:
> C:\programmes\eclipse\jre\bin\javaw.exe
> "javaw.exe in your current PATH"
>
> I have a file called jre that I have put in my Eclipse file but it does
> not contain an executable called javaw.exe...
>
> What can I do?
>
> Thanks for your help!
> Alexis
>
You need to have a Java Runtime Environment (JRE) installed on your
machine. You can get one of these from a few different sources. Once
it's installed, Eclipse should work fine.

For a list of suggested JREs, see:

http://download.eclipse.org/eclipse/downloads/drops/R-3.2.1- 200609210945/java-runtimes.html

HTH,

Wayne
Re: error message on setup [message #179138 is a reply to message #179136] Wed, 08 November 2006 22:19 Go to previous messageGo to next message
Eclipse UserFriend
If you intend to do any Java development you will need the JDK not a
JRE. The JRE can only run compiled Java code, but the JDK can compile
source to class files. If you want to use Eclipse for Java development
you will need the JDK. (Though Eclipse itself can be started with a JRE.)

> You need to have a Java Runtime Environment (JRE) installed on your
> machine. You can get one of these from a few different sources. Once
> it's installed, Eclipse should work fine.
>
> For a list of suggested JREs, see:
>
> http://download.eclipse.org/eclipse/downloads/drops/R-3.2.1- 200609210945/java-runtimes.html
>
>
> HTH,
>
> Wayne
Re: error message on setup [message #179141 is a reply to message #179136] Wed, 08 November 2006 22:19 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alexis_maubourguet.hotmail.com

Tahnks a lot Wayne!

It is now working, and I have begun the first tutorial "hello world!".
Nothing difficult would you think...

But when I run the application I created I get the following message:
"java.lang.NoClassDefFoundError: Helloworld (wrong name: helloworld)
at java.lang.ClassLoader.defineClass0(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)
Exception in thread "main"

Does it mean that I installed something incorrectly?

Thanks again!
Alexis
Re: error message on setup [message #179143 is a reply to message #179141] Wed, 08 November 2006 22:23 Go to previous messageGo to next message
Eclipse UserFriend
Alexis,

Did you name your class the same as the source file? If your filename
is Helloworld.java, then the class name must be Helloworld (not helloworld).

Joe


Alexis wrote:
> Tahnks a lot Wayne!
>
> It is now working, and I have begun the first tutorial "hello world!".
> Nothing difficult would you think...
> But when I run the application I created I get the following message:
> "java.lang.NoClassDefFoundError: Helloworld (wrong name: helloworld)
> at java.lang.ClassLoader.defineClass0(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)
> Exception in thread "main"
> Does it mean that I installed something incorrectly?
>
> Thanks again!
> Alexis
>
Re: error message on setup [message #179147 is a reply to message #179138] Wed, 08 November 2006 22:33 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wayne.beaton._NOSPAM_eclipse.org

Joe Skora wrote:
> If you intend to do any Java development you will need the JDK not a
> JRE. The JRE can only run compiled Java code, but the JDK can compile
> source to class files. If you want to use Eclipse for Java development
> you will need the JDK. (Though Eclipse itself can be started with a JRE.)
>
Uh... no.

Eclipse has its own Java compiler. The only reason that you might want
the JDK is to get access to the sources for the Java libraries (src.jar).

To be clear: Eclipse does not require the JDK. It does not use the
compiler provided with the JDK, it uses its own (and in my opinion,
better) compiler.

http://www-03.ibm.com/developerworks/blogs/page/Wayner?entry =did_you_know_that_eclipse

Wayne
Re: error message on setup [message #179150 is a reply to message #179143] Wed, 08 November 2006 23:14 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alexis_maubourguet.hotmail.com

Yes the class and the source file have exactly the same name, without any
capital letter (I do not understand why this error is raised). So I do not
know where the error comes from...

Maybe it has something to do with what you mentionned juste before: the
need for a compiler... Eclipse JDK does not play that role? if not,where
can I download a good compiler?

Thanks again
Alexis
Re: error message on setup [message #179195 is a reply to message #179150] Thu, 09 November 2006 09:02 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wayne.beaton._NOSPAM_eclipse.org

Alexis wrote:
> Yes the class and the source file have exactly the same name, without
> any capital letter (I do not understand why this error is raised). So I
> do not know where the error comes from...
>
> Maybe it has something to do with what you mentionned juste before: the
> need for a compiler... Eclipse JDK does not play that role? if not,where
> can I download a good compiler?
>
> Thanks again
> Alexis
>
Open the "Navigator" view and take a look at your project. Do you see
any files with a .class extension? If you do, then the compiler is
working fine.

Did you create the project as a "Java Project"?

What tutorial are you following?

Can you post the contents of the file you're having trouble with?

And no. You don't need an external compiler. Eclipse provides this.

Wayne
Re: error message on setup [message #179284 is a reply to message #179195] Thu, 09 November 2006 15:19 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: alexis_maubourguet.hotmail.com

Hello Wayne,

Thanks for your help!
Yes I have a helloworld.class file in my project Yes I created the project
as a java project I followed the "create a Hello World application"
tutorial which is part of the basic tutorials of the welcome of eclipse
jdk.

Here is the text of helloworld.java:

public class helloworld {

public static void main() {
System.out.println("Hello world");
}

}


Thanks again!
Alexis
Re: error message on setup [message #179312 is a reply to message #179284] Thu, 09 November 2006 15:54 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: wayne.beaton._NOSPAM_eclipse.org

Alexis wrote:
> Hello Wayne,
>
> Thanks for your help!
> Yes I have a helloworld.class file in my project Yes I created the
> project as a java project I followed the "create a Hello World
> application" tutorial which is part of the basic tutorials of the
> welcome of eclipse jdk.
>
> Here is the text of helloworld.java:
>
> public class helloworld {
>
> public static void main() {
> System.out.println("Hello world");
> }
>
> }
>
>
> Thanks again!
> Alexis
>
>
>
>
Your main method is wrong.

change it to:

public static void main(String[] args) {

}

and you should be good to go.

Wayne
Re: error message on setup [message #179327 is a reply to message #179312] Thu, 09 November 2006 18:36 Go to previous message
Eclipse UserFriend
Originally posted by: alexis_maubourguet.hotmail.com

It works!

Thanks a lot!

Alexis
Previous Topic:How to set up a CVS at SourceForge ?
Next Topic:Mess Code in Console with UTF-8 Encoding under Window Platform!
Goto Forum:
  


Current Time: Tue Jul 22 08:38:21 EDT 2025

Powered by FUDForum. Page generated in 0.11615 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top