My Windows 8
command prompt doesn't see java anymore. I found that in C:\ProgramData\Oracle\Java\javapath
located wrong symlink that I can't change. When I try change I got error:
Problem with Shortcut
The name 'C:\Program Files\Java\jre1.8.0_45\bin\javaw.exe' specified in the Target box is not valid. Make sure the path and file name are correct.
When I try to create shortcut I have message:
Windows can't create a shortcut here.
Do you want the shortcut to be placed on the desktop instead?
[Yes] [No]
How to solve this problem?
First Uninstall the java from your system, after remove the oracle folder in C:\ProgramData. Then again reinstall the java. Next click on javac.bat in bin folder of jdk.After check with command prompt like,
>javac
it will display all the options.then it's working perfectly...I think it's duplicate of
How to make a symlink in Java when running in Linux?
If you use java from the command prompt chances are high that you need to have correct JAVA_HOME variable set as well. Some tools depend on it.
To do it - edit the system environment variables:
Here is how you solve this problem :