| Author |
Creating a jar file from the command line
|
leo donahue
Ranch Hand
Joined: Apr 17, 2003
Posts: 327
|
|
I have a swing based application in a package called moiveJava2. My moment interval class, WindowGUIMI, has one main method which instantiates the rest of the application from another class called WindowGUI. I have created a manifest file called MovieJava2.MF which has one line equal to: Main-Class: WindowGUIMI //plus a carriage return My dos command lines thus far have been: C:\java_programs\MovieJava>jar cvf MovieJava2.jar movieJava2\* C:\java_programs\MovieJava>jar cmf MovieJava2.MF MovieJava2.jar movieJava2\*.class When I double click on the jar file I get a JVM Launcher error dialog which says: "Could not find the main class. Program will exit". What have I done wrong here?
|
Thanks, leo
|
 |
Jessica Sant
Sheriff
Joined: Oct 17, 2001
Posts: 4313
|
|
how about trying to change your Main class def'n to: Main-Class: moiveJava2.WindowGUIMI //plus carriage return so it specifies the fully qualified class name of your application?
|
- Jess
Blog:KnitClimbJava | Twitter: jsant | Ravelry: wingedsheep
|
 |
leo donahue
Ranch Hand
Joined: Apr 17, 2003
Posts: 327
|
|
Jessica, You are the best! That worked. Thanks!
|
 |
 |
|
|
subject: Creating a jar file from the command line
|
|
|