• Post Reply Bookmark Topic Watch Topic
  • New Topic

Trouble running Java program from command line  RSS feed

 
M Burke
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I bundled my app in a .jar file. I told it where my main is, but I get a error from the JVM when I try to run it "Could not find main class. Program will exit"

Here is my command line with an argument...

javaw EasyCheckup "c:\easycheck.csv"

I am running this from the same dir as the jar file named EasyCheckup.jar. The current dir is in my classpath
 
Dmitry Melnik
Ranch Hand
Posts: 328
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
javaw -cp {your classpath including your apps jar} {your class name} {parameters for your app}
 
Marilyn de Queiroz
Sheriff
Posts: 9082
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You may find some help in this thread on executable jars.
 
M Burke
Ranch Hand
Posts: 410
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I appreciate your help. I'm over that hump now
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!