Environment variables to point to the Java compiler

derek2809

New member
Local time
3:48 PM
Messages
12
Hi everyone

I have recently installed the Java Development Kit 6 in my Windows 7 Ultimate 32 bit installation but not been able to set the path to the javac compiler in the Environment Variables. What I have done so far is:

  1. Opened the Environment Variables dialog obx
  2. Created a new PATH to C:\Program Files\Java\jdk1.6.0_20\bin under User Variables
  3. Added C:\Program Files\Java\jdk1.6.0_20\bin to the right end of the series of directories called 'Path' under System Variables
The instructions on this in the Oracle website seems to be written for Windows XP and apparently different setup is required for Windows 7. All I want to do is every time I launch Command Prompt, the Prompt knows where javac.exe is so it can execute it without my typing the path to the compiler.

I would like to have as much as avice/instructions as possible because it has been nagging me for quite some time and irresolvable.

Thank you in advance,

Derek
 

My Computer

Computer Manufacturer/Model Number
N/A
OS
Windows 7 Ultimate x64
Motherboard
Intel Desktop Board DZ77SL-50K
Memory
4GB DDR3 x 4
Hard Drives
3GB Seagate SATA
Opened the Environment Variables dialog obx
  1. Created a new PATH to C:\Program Files\Java\jdk1.6.0_20\bin under User Variables
  2. Added C:\Program Files\Java\jdk1.6.0_20\bin to the right end of the series of directories called 'Path' under System Variables
You don't want to add a new user variable for PATH.

You just want to add your Java JDK bin library TO THE END OF THE EXISTING PATH VARIABLE that currently exists in the system area of the environment variables, as you've done (presumably you've correctly prefixed this new appendage with a ";" to separate it from the prior item in the existing PATH list). That really should work.
 

My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Home-built, two systems (1) and (2)
OS
Windows 7 Pro x64 (1), Win7 Pro X64 (2)
CPU
i5-3350p 3.1Ghz/6MB-cache (1); E8400 3.0Ghz/6MB-cache (2)
Motherboard
ASUS P8Z77-V Pro (1); ASUS P5Q3 (2)
Memory
8GB PC3-12800 DDR3 (1); 4GB PC3-10600 DDR3 (2)
Graphics Card(s)
ATI HD7750 (1), (see TV cards); ATI R7 250 (2)
Sound Card
Realtek ALC892 HD Audio (1); Realtek ALC1200 HD Audio (2)
Monitor(s) Displays
Eizo HD2441W LCD, Eizo S2433W (1); Eizo 24" S2433W (2)
Screen Resolution
1920x1200, 1920x1200 (1); 1920x1200 (2)
Hard Drives
(1) 1TB SATA-II (7200RPM), 2x2TB SATA-III (7200RPM), 250GB SATA-III (10000RPM) for OS; 2x2TB external USB 3.0

(2) 320GB SATA-II (7200RPM), 750GB SATA-II (7200RPM), 150GB SATA-II (10000RPM) for OS; 2TB external USB 3.0
PSU
Nesteq ECS-6001 600W (1); Nesteq ECS-5001 500W (2)
Case
Acousti-Case 360 (1) and (2)
Cooling
Noctua NH-U12P SE2 for CPU, 2x120mm case fans (1) and (2)
Keyboard
IBM PS/2 (1) and (2)
Mouse
Logitech MX Revolution wireless (1); Microsoft wired (2)
Internet Speed
100mbps down / 10mbps up
Antivirus
Microsoft Security Essentials; Malwarebyte Anti-Malware Pro
Browser
Firefox
Other Info
Ceton InfiniTV 4-tuner cablecard-enabled TV card as well as Hauppauge HVR-2250 OTA/ATSC 2-tuner TV card in (1), running under Win7 WMC
Yes, I also tried adding the path to the JDK directory to the right end of the system variable Path with no luck. In that incident I did not include PATH to the users variable. Command Prompt returned:

'javac' is not recognized as an internal or external command,
operable program or batch file.

Any more advice would be appreciated.
 

My Computer

Computer Manufacturer/Model Number
N/A
OS
Windows 7 Ultimate x64
Motherboard
Intel Desktop Board DZ77SL-50K
Memory
4GB DDR3 x 4
Hard Drives
3GB Seagate SATA
Back
Top