• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Bear Bibeault
  • Henry Wong
  • Devaka Cooray
Saloon Keepers:
  • salvin francis
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Frits Walraven
Bartenders:
  • Jj Roberts
  • Carey Brown
  • Scott Selikoff

Chapter 1 - Advice Client

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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.
 
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
It's a tiny ad only because the water is so cold.
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic