aspose file tools
The moose likes Beginning Java and the fly likes Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark ""could not find main class: program will exit"" Watch ""could not find main class: program will exit"" New topic
Author

"could not find main class: program will exit"

Jesse Crockett
Ranch Hand

Joined: Feb 03, 2005
Posts: 129
Not a programming question, but I'm trying to install azureus. Their jar file will not open on windows. I have the java JRE installed. Apparently there is no CLASSPATH setting in the environment variables. It is not there. What do I do?
Jesper de Jong
Java Cowboy
Bartender

Joined: Aug 16, 2005
Posts: 12909
    
    3

Is it an executable JAR file (i.e., a JAR file which you double click to run)? If so, then the CLASSPATH environment variable is not applicable. In an executable JAR file, the classpath in the manifest file which is inside the META-INF directory in the JAR file determines the classpath.

The error message might mean that there's something wrong with the JAR file (maybe it's corrupted in some way?). Are you sure that you're using the right version of Java?

If it's not an executable JAR, but a command batch file (*.bat or *.cmd) that you use to start the program, then look in the file to see how it exactly starts up the program.
[ January 15, 2007: Message edited by: Jesper Young ]

Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 7 API documentation
Scala Notes - My blog about Scala
Jesse Crockett
Ranch Hand

Joined: Feb 03, 2005
Posts: 129
Yes, it is an executable jar.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: "could not find main class: program will exit"
 
Similar Threads
printing on an applet
JUnit and Cactus using strutstestCase
Assert stmt in Eclipse
Dynamic Data Types in Eclipse
Automatically reconnect to server ?