
6th April 2011, 05:02 PM
|
Member
|
|
Join Date: Sep 2005
Posts: 1,601
|
|
shaun, Youngbuck,
If you get issues with "'javac' is not recognized as an internal or external command, operable program or batch file".
It means that the environment path has not been setup correctly. To fix this find the directory that hs javac.exe in it (it will be in your JDK directory\bin).
Go to the control panel in windows and go to System. Half way down you should see something about Computer Name, Workstation, etc. There is a change setting sbutton here. Click that and another screen opens. Go To advanced. Click on Environment Variables. In the bottom section you should see an entry called Path. Edit this entry and add in the directory where you found the javac.exe file.
For example my path currently is:
%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\Sy stem32\Wbem;C:\PROGRA~1\COMMON~1\ULEADS~1\MPEG;c:\ Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\MySQL\MySQL Server 5.1\bin;C:\Program Files\IEInspector\HTTPAnalyzerFullV6\;%SYSTEMROOT% \System32\WindowsPowerShell\v1.0\
If javac.exe was in c:\java\bin\javac.exe I would change the above to be:
%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\Sy stem32\Wbem;C:\PROGRA~1\COMMON~1\ULEADS~1\MPEG;c:\ Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\MySQL\MySQL Server 5.1\bin;C:\Program Files\IEInspector\HTTPAnalyzerFullV6\;%SYSTEMROOT% \System32\WindowsPowerShell\v1.0\;c:\java\bin\
Notice the use of ; to seperate the directory paths. You may need to restart windows to pick it up (sometimes you don't). It should then find javac from any directory.
|