Re: java

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2002-11-12 at 04:37, anthony baldwin wrote:
> Hey, 
> What the heck does this mean?  I was trying to run a java hangman game.
> 
> [root@localhost programs]# java -jar swingman.jar
> Warning: -jar not understood. Ignoring.
> Exception in thread "main" java.lang.NoClassDefFoundError: swingman.jar

Anthony,

The version of java that you are running does not understand the -jar
option.  What version are you running?  Try java -v.

Do you know the name of the class to run in the jar?  A quick way to
find out what class to run do the following:

unzip -c ./swingman.jar manifest | grep Main-class

(man unzip and man grep will help you understand what this is doing) You
should get output like:

Main-Class: mypackage.MyClass

If so, you can do this:

java -classpath ./swingman.jar mypackage.MyClass

Hope this helps,
-- 
Philip A. Chapman

Application Development:
Java, Visual Basic, VB for Applications, PostgreSQL, MySQL, MSSQL
Linux, Windows 9x, Windows NT, Windows 2000, Windows XP

Attachment: signature.asc
Description: This is a digitally signed message part


[Index of Archives]     [Fedora General Discussion]     [Red Hat General Discussion]     [Centos]     [Kernel]     [Red Hat Install]     [Red Hat Watch]     [Red Hat Development]     [Red Hat 9]     [Gimp]     [Yosemite News]

  Powered by Linux