This week's giveaway is in the Programmer Certification (OCPJP) forum.
We're giving away four copies of Java Mock Exams (software) and have David Mayer on-line!
See this thread for details.
Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

NX:jar file path

 
guyue0505
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I create a jar file like :
1)jar -cvfm client.jar manifest_client.mf suncertify\client\*.class suncertify\db\*.class
2)jar -cvfm server.jar manifest_server.mf suncertify\server\*.class suncertify\db\*.class
manifest_client.mf like:
Manifest-Version: 1.0
Created-By: 1.4.0 (Sun Microsystems Inc.)
Main-Class: suncertify.client.client
manifest_server.mf like:
Manifest-Version: 1.0
Created-By: 1.4.0 (Sun Microsystems Inc.)
Main-Class: suncertify.server.server
So i create client.jar and server.jar Ok;
and last i run like this:
java -jar sever.jar ; But some errors occurs:
Exception in thread "main" java.lang.NoClassDefFoundError: suncertify/server/ser
ver
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Posts: 12056
232
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Steven
Dont the new exams require you to have a single jar file named "runme.jar" for both client and server?
Even if you do have that requirement, I think we should ignore it for the moment, and try and solve your current problem. Otherwise you are likely to have the same problem when you try and meet the requirement.
OK, obvious questions first.
Can you run the server by running:

If you run the command
Do you get the response:
Regards, Andrew
[ June 24, 2003: Message edited by: Andrew Monkhouse ]
[ June 24, 2003: Message edited by: Andrew Monkhouse ]
 
Mark Spritzler
ranger
Sheriff
Posts: 17309
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Steven"-
Please adjust your displayed name to meet the
JavaRanch Naming Policy.
You can change it
here.
All you need to do is to add your last name.
Mark
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!