• Post Reply Bookmark Topic Watch Topic
  • New Topic

How should I set up the Java_Home Path  RSS feed

 
Daithi Moore
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I have downloaded and Installed Java SE Development Kit 8. I am using Windows 8.1

I seen the instructions below for setting the JAVA_HOME and PATH environment variables. These insructions apply to Vista and Windows 7. I presume they also apply to Windows 8.1 also.

Could someone confirm that they do?

I am confused though by the instructions. The instructions say not to set a user Java_Home and a system Path and later it says set the variable name as Java_Home. I have highlighted those instructions in bold.

Could someone help me set this up correctly as i dont want to mess up the settings.

Thank you

Instructions from How to Create your first Java Program
Windows Vista / Windows 7

Start/Control Panel.
Double-click System, and select "Advanced system settings" on the left.
On the "Advanced" tab, click the Environment Variables button.
You can set environment variables for either your user only, or for all users (System variables). But don't set a user JAVA_HOME and a system PATH (see this discussion). Add a new variable in either of them by clicking the New button.
Set the variable name as JAVA_HOME, and its value to the directory where you installed the JDK (e.g. C:\java\jdk1.7.0_72)
Click OK.
Look for a variable called PATH (the name might slightly vary, for example 'Path'). Select it and click Edit. At the beginning of its value, add the following : "%JAVA_HOME%\bin;" (without the double quotations). Don't forget the semi-colon at the end, to separate this directory to the other directories already in the path.
Click OK and close all remaining windows.
On Windows 7 it may be necessary to reboot your PC before the new environment variables are recognised
 
Jeff Boynton
Greenhorn
Posts: 18
Android Chrome Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Windows 8.1 and 7 are the same
 
Tony Docherty
Bartender
Posts: 3271
82
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am confused though by the instructions. The instructions say not to set a user Java_Home and a system Path and later it says set the variable name as Java_Home. I have highlighted those instructions in bold.

When you set an environment variable you can set it to be at user level or system level. If you set it at user level then it will only apply to the currently logged in user's profile which means if you or anyone else logs into that computer using a different login then those environment variables won't be available to them. So what it is saying is make sure you create the environment variables at system level so they are available to all users.

Personally speaking I don't like instructions like that as there may be very good reasons why you only want Java to be available to a particular user.
 
Daithi Moore
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for the replies,

Are there any risks with using the System Level setting.

I have noticed that my Firefox Browser disables Java Deployment Toolkit 8.0.250.18 saying that it is known to be vulnerable.

Im wondering if there is a risk using the System Level setting seeing as SDK is a Java Prodcut.

If someone could provide the direct link to the API I need it would be a great help.

I have looked here http://docs.oracle.com/javase/8/docs/ and downloaded the JDK 8 documentation but I cant see where the API is.

Sorry for all the Qs but this is completely new to me.

Thank you
 
Tony Docherty
Bartender
Posts: 3271
82
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are there any risks with using the System Level setting.

The only risks are those I've outlined ie other users would have access to Java. Whether you feel this is a risk or not is down to you and how you use and who uses your computer.
I have noticed that my Firefox Browser disables Java Deployment Toolkit 8.0.250.18 saying that it is known to be vulnerable.

Im wondering if there is a risk using the System Level setting seeing as SDK is a Java Prodcut.

Using system level or not has nothing to do withyour browser or any plugins installed in it.

If someone could provide the direct link to the API I need it would be a great help.

Do you mean the API docs? You say you have downloaded them so open them in a browser and click on the "Java SE API" link. On the download page you quoted the link is on the far right of the Java stack diagram.
 
Daithi Moore
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Tony,

I had previously downloaded the JDK 8 documentation on the left hand side.

I clicked on the API link on the right of the stack and there are many different packages.

Which one do I need?
 
Tony Docherty
Bartender
Posts: 3271
82
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The API is divided into lots of packages each containing many classes. Together they make up the API so it's not really a case of which one do you need, you get them all and will probably only ever use about 10% of them.
 
Campbell Ritchie
Marshal
Posts: 56592
172
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since they live in a single file called rt.jar, you won't even notice which classes there are.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!