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

Chapter 1 - Advice Client

 
Senthil K Kumaran
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When I compile the AdviceClient, I'm getting error 'headfirst' package does not exist.

I gave following compile command from my project directory (c:ejbprojects\advice)

javac -classpath {$CLASSPATH}:AdviceAppClient.jar;C:\j2sdkee1.3.1\lib\j2ee.jar AdviceClient.java

I got following error...

AdviceClient.java:18: package headfirst does not exist (for all headfirst package classes).

But when I extract the AdviceAppClient.jar file to project directory (c:\ejbprojects\advice) and compiled using following command, it worked fine ( Also I ran the client and got the expected results)

javac AdviceClient.java

Any idea! Why I could not directly use AdviceAppClient.jar file during the compilation.
 
Puneet Vashisht
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hii ,

You can use this command for Windows environment:
javac -classpath %CLASSPATH%;AdviceAppClient.jar;. AdviceClient.java

With HF they ppl have worked it out on unix environment.
As to why you cant directly write java AdviceClient : You must actually be able to tell the client where are your classes located.


Thankz
Puneet

SCJP 1.4
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic