Ok, I had this problem and this is what fixed it for me. For writing, I use Windows 8.1 and Java JDK 1.8.31, all 64-bit.
The problem is a gap between the "Program" and the "Files" in the path set to JAVA_HOME . I used to have this problem, but I did not understand, until I checked the instructions here to install JAVA HOME , then all this made sense.
In a nutshell, change the JAVA_HOME path:
C:\Program Files\Java\jdk1.8.0_31
to
C:\Progra~1\Java\jdk1.8.0_31
Be sure to set the correct JDK version number for your installation. Removing space from the path eliminates everything in my system.
As indicated on the page above
use C:\Progra~1\ for C:\Program Files\
and C:\Progra~2\ for C:\Program Files(x86)\
depending on where the JDK is installed on your system.
Note. Before making this change, my system correctly repeated the value of JAVA_HOME as C:\Program Files\Java\jdk1.8.0_31 in the command window, making me believe that everything was fine. However, an attempt to start %JAVA_HOME%\bin\javac reported that the path was not found. After removing the space from the JAVA_HOME path, the same command runs fine.
randall Jan 21 '15 at 20:26 2015-01-21 20:26
source share