Java environment variable configuration in Windows 8

Source: Internet
Author: User

Configure Java environment variables in Windows 8

Windows 8 is Microsoft's latest and most revolutionary operating system. The system aims to make people's daily computer operations easier and faster, and provide people with an efficient and easy-to-use work environment. At present, Microsoft officially provides Windows 8 system downloads. I believe many early adopters are already experiencing this.

In fact, the configuration of Java environment variables in Windows 8 is similar to that in Windows 7/XP. This article describes how to configure Java environment variables in Windows 8.

Install the latest JDK version

First, download the latest JDK 1.7.0 _ 06 on the official Oracle website. (There are many JDK versions. We will select the latest version ).

The official JDK download page is http://www.oracle.com/technetwork/java/javase/downloads/index.htmland select (and remember) your installation directory (the final installation directory of the blogger is: e: \ Program Files \ Java \ jdk1.7.0 _ 06 ).

There is no big difference between JDK installation and general software installation. Pay attention to the installation path you selected. We recommend that you do not install JDK in a path containing Chinese characters, otherwise, various unrecognized problems may occur in future use.

After JDK is installed, enter windows (that is, the key for drawing the Microsoft trademark on the keyboard) + R, enter "cmd", and then press Enter.

In this case, the console interface appears. Enter Java and press enter to display the content as shown in figure (if it does not appear, it does not matter. In the control panel, view the content as an icon, check whether the "Java" icon exists. If yes, it indicates that JDK has been installed. Otherwise, reinstall JDK.) This indicates that JDK has been installed successfully;

Then, if you enter javac, the prompt "'javac' is not an internal or external command, or a program or batch file that can be run ." The configuration of Java environment variables is required.

The above steps are limited to the latest Windows 8 system. In fact, you only need to enter the console. Here, you only provide a way to enter the console. If you have a unique way to go to the console, you are welcome to leave a comment and share it with you.

JDK environment variable configuration

Type windows + X and click "Control Panel" in the "shortcut navigation" in the lower left corner ", in the upper left corner of the control panel, select "view mode" as "small icon" (if the classification mode is category, you may [go crazy] If you cannot find the "System" icon.), Find the system header and click to enter.

Select "Advanced System settings" in the upper left corner of the "System" Panel, select "advanced" in the pop-up system properties, and click "environment variable (n)" in the lower right corner )... to configure the Java environment variables.

Of course, if your desktop has a "computer" shortcut, you can also right-click and select "properties" and enter the "System" panel. In the past, you can click "start" to find "computer" in Windows 7, but this is because Windows 8 does not have a "start" menu.

In the following "system variables (s)" box, create two new environment variables.Java_homeAndClass_pathClick "New (w ...)".

Variable name:Java_home

Variable value:E: \ Program Files \ Java \ jdk1.7.0 _ 06

Variable name:Class_path

Variable value:.; % Java_home % \ Lib \ DT. jar; % java_home % \ Lib \ tools. Jar

[Note that there is a dot in front to indicate the current path]

ModifyPathEnvironment variable, select "path", in the variable valueLastAdd:

; % Java_home % \ bin; % java_home % \ JRE \ bin[Note that you should add a semicolon before]

Then, click "OK" and "application", and then enter "cmd" in Windows + r according to the preceding steps to enter the console, now, no matter you enter commands such as "Java", "javac", and "Java-version", they are displayed successfully.

Now you can compile and debug console programs in the console. For [cainiao-level] Beginners, it is particularly important to explore in the console.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.