0
Having trouble running the first program
I'm trying to get the first Hello World program to run. I've compiled the .java file and when I attempt to run the .class file I get this: "The system cannot find the file C:\ProgramData\Oracle\Java\javapath\java.exe". I've found this file in a different location however. Not sure what to change or how to fix the problem
7 Respuestas
0
It seems your Java path system variable has not been set correctly. Go to chapter 3 "Installing the JDK" part 3 "JDK & PATH" and check the instructions to set the path.
0
I double checked the location and did the test to ensure that it's working properly. I'm really not sure what it could be.
0
I have cmd open to the directory that contains the class file, and then I type "java ExampleProgram".
0
Did you compile it before trying to run?
0
Yes, it's compiled as a .class file
0
What did you set as path variable?
0
Not at my computer atm, but the path leads to the jdk bin folder.