Ask Your Question

Revision history [back]

java won't run

Hi,

I'm new to using Fedora 23 and I'm trying to compile and run Java programs. My problem is that the program will not run, it compiles fine but when I try to run it I get an error message which says "Could not find or load main class .home.myname.Documents.Ex1_1". The commands I use to compile and run are (after entering root access):

javac /home/myname/Documents/Ex1_1.java java /home/myname/Documents/Ex1_1 and Ex1_1.class

I've verified that openJDK is up-to-date.

Thanks

click to hide/show revision 2
No.2 Revision

updated 2016-03-07 05:08:51 -0500

hhlp gravatar image

java won't run

Hi,

I'm new to using Fedora 23 and I'm trying to compile and run Java programs. My problem is that the program will not run, it compiles fine but when I try to run it I get an error message which says "Could not find or load main class .home.myname.Documents.Ex1_1". The commands I use to compile and run are (after entering root access):

javac /home/myname/Documents/Ex1_1.java
java /home/myname/Documents/Ex1_1
and Ex1_1.class

Ex1_1.class

I've verified that openJDK is up-to-date.

Thanks