Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem on HFEJB P57,P58

 
Ray Yu
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all JavaRanch professional:

I have a problem in running the book example code in HFEJB P57, P58.
When I do all the things in application deployment tool(RI).
Then I compile the code and run the class file

I use WinXP and install J2SDK1.4.01, J2EE1.3 to run the code.
I follow the book deploy step to deploy the code
I use the follow command to compile the code (that ok, No warning or error)-
"javac -classpath c:\j2sdkee1.3.1\lib/j2eejar;AdviceAppClient.jar AdviceClient.java"

Then I use the follow command to run the class file
"java -cp c:\j2sdkee1.3.1\lib/j2eejar;AdviceAppClient.jar AdviceClient"
The problem occurs, It show!
"Exception in thread "main" java.lang.NoClassDefFoundError: AdviceClient"

What 's going on!


Please Help Me..........
 
Ray Yu
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all JavaRanch Professional

Sorry, I have typo in the above message

The command I use to compile is
"javac -classpath c:\j2sdkee1.3.1\lib\j2ee.jar;AdviceAppClient.jar AdviceClient.java"

The command I use to run the class file is
"java -cp c:\j2sdkee1.3.1\lib\j2ee.jar;AdviceAppClient.jar AdviceClient"

The error of NoClassDefFoundError is show, please help me....
 
Nicholas Cheung
Ranch Hand
Posts: 4982
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Such question has been asked many many times here already, why dont you do a search first?

http://www.coderanch.com/t/158494/java-EJB-SCBCD/certification/these-errors-pg-head-first

Nick
 
Ray Yu
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
After I saw the previous post, I solve the problem.
Thanks Nicholas
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic