|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Path not set right ???
Hey there, im having a wee bit o' trouble with setting the path to javac.
Not sure what im doing wrong, or if its just a window$ problem, (Using windows xp sp2) Ive added the line to my bin under system variables so my path variable is: %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\Sy stem32\Wbem;"C:\Program Files\Java\jdk1.5.0\bin\javac" For some reason i can compile if I type out the whole path in the command prompt window as: C:\MyJava> "C:\Program Files\Java\jdk1.5.0\bin\javac" MyClass.java But when i try: C:\MyJava> javac MyClass.java ... i get the following error: 'javac' is not recognized as an internal or external command, operable program, or batch file. Any ideas what im doing wrong would save a lot of typing in the near future. Thanx. PS Ive tried setting the path with just \bin, instead of \bin\javac with and without the quotes, under both user and system variables. ive typed C:\> path to make sure that it was set and it is, and I can use the command C:\MyJava> java MyClass without any problems after i managed to compile it using the entire command line arg. |
|
#2
|
||||
|
||||
|
set path so it points to the bin folder, not javac directly.
example: %SystemRoot%\system32;%SystemRoot%;%SystemRoot%\Sy stem32\Wbem;"C:\Program Files\Java\jdk1.5.0\bin\" I'm pretty sure you need the quotes since "Program Files" has a space... on that note, it might be best to install Java in a folder that *doesn't* have a space... like C:\java for the sake of testing, you could always cal javac as an absolute path... "C:\Program Files\Java\jdk1.5.0\bin\javac.exe MyClass.java" Let us know if anything I've offered works... there might be a bigger problem.. |
|
#3
|
|||
|
|||
|
U still having trouble with that cause i have a solution for you. I had the same problem and this fixed it.
go to your environment variables and find the one called path. Click edit and add the following to the end of it. I did this and it fixed it and now I have it up and running. ;"C:\Program Files\Java\jdk1.5.0\bin"; |
|
#4
|
|||
|
|||
|
Thanx =)
Sorry about the lateness of the thank you here, but
Thank You =) Im sure i may have more questions in the near future as this semester I will be doing a lot of programming in Java building an OS using the MOSS simulator http://www.ontko.com/moss/ |
|
#5
|
|||
|
|||
|
Quote:
I would like to add my thanks to you for your help, I tried the above and it is working fine after looking for days on the net for solution. URLURLURL |
![]() |
| Viewing: Dev Articles Community Forums > Programming > Java Development > Path not set right ??? |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|