Home > Back-end >  Win 7 system with 8 how to install Java, Java - version is available, but javac show is not internal
Win 7 system with 8 how to install Java, Java - version is available, but javac show is not internal

Time:10-03

I'm of new, entering the programming, you help me have a look, my system is Windows 7 64 - bit, JDK installation don't understand, download jdk1.8, installed in: C: \ Program Files \ Java \ jre1.8.0 _144, troublesome everybody out a detailed tutorial, many times to find the answer on the net also not line, so please everybody

CodePudding user response:

I use this app # CSDN# found have technical content of the blog and friends to seek common to JAVA environment configuration, gathered together at https://blog.csdn.net/weixin_44155115/article/details/103827693? Utm_source=app

CodePudding user response:

1. The JDK is installed, the Java directory should have two folders: jdk1.8 jre1.8 XXX and XXX, if you don't have a random change,
2. If it is completely white, it is recommended that you reinstall after uninstall Java, direct the default path,
3. After the installation is complete, need to configure the Windows environment variable (usually, the JDK will give you the default configuration is good, but most of the Java program apes like manual configuration)
Configuration methods:
 
Under Windows configuration JDK environment variables:
1. Right click on the "my computer" and click "properties";

2. Select the "advanced" TAB, click on the "environment variables";

3. In the "system variables", set up three attributes, JAVA_HOME, PATH, the CLASSPATH (case doesn't matter), if existing then click "edit", there is no click on the "new";

4. JAVA_HOME indicate the JDK installation path, is just install the selected path c: \ XXXX \ jdk1.8 XXX, including lib under this path, bin, jre etc folder (this variable is best, because after running tomcat, eclipse and so on all need to rely on the variable).

Path makes the system can identify the Java command under any Path, set to: % JAVA_HOME % \ bin; % JAVA_HOME % \ jre \ bin

CLASSPATH for Java class (class/lib) path, only the class in the CLASSPATH, the Java command to identify, set to:; The % JAVA_HOME % \ lib \ dt. Jar; % JAVA_HOME % \ lib \ tools. Jar (want. Said the current path)

Specify the JAVA_HOME % JAVA_HOME % is in front of the reference and

6. "start" - & gt;; "Run" and type in "CMD";

7. Type the command "Java - version", "Java" and "javac" a few commands, a picture that environment variable configuration success

CodePudding user response:

1. Right click on the "my computer" and click "properties";
2. Select the "advanced" TAB, click on the "environment variables";
3. In the "system variables", set up three attributes, JAVA_HOME, PATH, the CLASSPATH (case doesn't matter), if existing then click "edit", there is no click on the "new";

JAVA_HOME:
Indicate the JDK installation path, it is just when installation of the selected path C: \ \ jdk1.8 XXX XXX, including lib under this path, bin, jre etc folder (this variable is best, because after running tomcat, eclipse and so on all need to rely on the variable).


Path:
Makes the system can identify the Java command under any path, set to: % JAVA_HOME % \ bin; % JAVA_HOME % \ jre \ bin

The CLASSPATH:
Load for the Java class (class or lib) path, only the class in the classpath, the Java command to identify, set to:

.; The % JAVA_HOME % \ lib \ dt. Jar; % JAVA_HOME % \ lib \ tools. Jar (want. Said the current path)


6. "start" - & gt;; "Run" and type in "CMD";

7. Type the command "Java - version", "Java" and "javac" a few commands, a picture, show success environment variable configuration
  • Related