![]() |
![]() |
![]() |
|||||
![]() |
![]() |
![]() |
![]() |
![]() |
|||
| Welcome
to Tech Support Forum home to more then 136,000 problems solved. Issues
have included: Spyware, Malware, Virus Issues, Windows, Microsoft,
Linux, Networking, Security, Hardware, and Gaming Getting your
problem solved is as easy as: 1. Registering for a free account 2. Asking your question 3. Receiving an answer Registered members: * See fewer ads. * And much more..
|
| Want to know how to post a question? click here | Having problems with spyware and pop-ups? First Steps |
|
|||||||
| Programming A discussion forum for programs and programming used in tech-related businesses. |
![]() |
|
|
LinkBack | Thread Tools |
|
|
#1 (permalink) | |
|
Registered User
Join Date: Jan 2008
Posts: 47
OS: xp sp2
|
[SOLVED] Java command prompt problem
I am learning to program in Java using the JDK, the notepad, and the windows command prompt. Every time I try to use the javac command, it says:
'javac' is not recognized as an internal or external command, operable program or batch file. I have been able to get it to compile by putting the whole path in manually like this: "C:\Program Files\Java\jdk1.6.0_16\bin\javac" Hello.java The teacher anticipated that we would get this sort of problem so he posted this as a fix: Quote:
|
|
|
|
|
| Important Information |
|
Join the #1 Tech Support Forum Today - It's Totally Free!
TechSupportForum.com is a leading support website for your computer needs. We offer free, friendly and personalized computer support. Why pay to have your computer fixed when you can do it for free. Join TechSupportforum.com Today - Click Here |
|
|
#3 (permalink) |
|
TSF Enthusiast
Join Date: Mar 2009
Location: Portland, OR
Posts: 834
OS: MS-Dos 6.22 - Win7
|
Re: Java command prompt problem
It looks to me like you have a space between the ; and the C:\Program Files\Java\jdk1.6.0_16\bin\.
If there is a space there it won't work
__________________
Microsoft MVP - Windows Desktop Experience Of course I know all the answers; I just don't always match the answers to the right questions. Rated R for Violence -- When your PC flies through a window, that's violent, right? |
|
|
|
|
|
#4 (permalink) |
|
God (TSF Enthusiast)
Join Date: May 2009
Location: Jeffersonville, IN
Posts: 905
OS: Ubuntu 9.10 [Karmic Koala]
|
Re: Java command prompt problem
So it's "\;C:\Program Files\Java\jdk1.6.0_16\bin\javac" right? I've never used notepad to compile java. Now that I'm running a linux box it will likely never happen :-P
|
|
|
|
|
|
#5 (permalink) |
|
TSF Enthusiast
Join Date: Mar 2009
Location: Portland, OR
Posts: 834
OS: MS-Dos 6.22 - Win7
|
Re: Java command prompt problem
Yes, no space after the ;
__________________
Microsoft MVP - Windows Desktop Experience Of course I know all the answers; I just don't always match the answers to the right questions. Rated R for Violence -- When your PC flies through a window, that's violent, right? |
|
|
|
|
|
#7 (permalink) | |
|
TSF Enthusiast
Join Date: Mar 2009
Location: Portland, OR
Posts: 834
OS: MS-Dos 6.22 - Win7
|
Re: Java command prompt problem
Quote:
The trailing slash is optional, it can be omitted or left in, but you can't include the file name javac. The path statement is always just folders. And there is more to the left of the first \, it's just not visible in the screen shot. At a minimum you would have this for the Path variable in Windows: C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Program Files\Java\jdk1.6.0_16\bin Glad it's working for you now Tecnoob! If your issue has been resolved you can mark this thread Solved by using the Thread Tools at the Top Right of this thread (above the first post) ![]() Jerry
__________________
Microsoft MVP - Windows Desktop Experience Of course I know all the answers; I just don't always match the answers to the right questions. Rated R for Violence -- When your PC flies through a window, that's violent, right? |
|
|
|
|
![]() |
| Thread Tools | |
|
|