• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Classpath variable in Eclipse

 
Ranch Hand
Posts: 226
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have both Java 1.5 and Eclipse installed on my computer. When I try to execute a program using Eclipse, I get a message that says that it cannot find, C:\apps\Java\jre1.5.0_11/lib/tools.jar

I know that the file, tools.jar, is found in C:\apps\Java\jre1.5.0_11. Should I change the classpath variable from C:\apps\Java\jre1.5.0_11 to C:\apps\Java\jdk1.5.0_11? If so, how would I do that?
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
(not sure about English menus)
In Windows->Settings...->Java->Installed JRE, make sure that your JRE is there. If it's not, add it.
 
Fred Victa
Ranch Hand
Posts: 226
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I already have JRE installed. My program is saying that it cannot find tools.jar in JRE. Is tools.jar supposed to be in JRE? I know that tools.jar is found in JDK. If the program is supposed to look for tools.jar in JDK, but not in JRE, how would I change that?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I already have JRE installed.


Does it point to your JDK ? (not JRE only) It should be associated to C:\apps\Java\jdk1.5.0_11
 
Fred Victa
Ranch Hand
Posts: 226
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't think it points to JDK. How would I make it point to it?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In Windows->Settings...->Java->Installed JRE, click the Add... button. In JRE Home Directory, click the Search... button, and select your JDK directory (C:\apps\Java\jdk1.5.0_11). Give it the name you want, and click OK. Back to the Installed JRE window, check the JDK you have added (this will make it the default JRE for your projects.).
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic