This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes problem while compiling Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "problem while compiling" Watch "problem while compiling" New topic
Author

problem while compiling

Shankar Arumugam
Greenhorn

Joined: Oct 05, 2005
Posts: 14
While compiling servlet verssion two of BeerSelect program in HFSJ,I got
the following error


D:\MyProjects\beerV1>javac -d classes src\com\example\web\BeerSelect.java
src\com\example\web\BeerSelect.java:3: package com.example.model does not exist
import com.example.model.*;
^
src\com\example\web\BeerSelect.java:18: cannot resolve symbol
symbol : class BeerExpert
location: class com.example.web.BeerSelect
BeerExpert be = new BeerExpert();
^
src\com\example\web\BeerSelect.java:18: cannot resolve symbol
symbol : class BeerExpert
location: class com.example.web.BeerSelect
BeerExpert be = new BeerExpert();
^
3 errors

D:\MyProjects\beerV1>

So help me to compile the program.

note: Servlet version 1 is working properly.
Shivani Chandna
Ranch Hand

Joined: Sep 18, 2004
Posts: 380
You will need to set the BeerExpert class in the classpath at the time of compiling the code.

Rgds,
Shivani


/** Code speaks louder than words */
Mohd Fuzail
Ranch Hand

Joined: Feb 20, 2002
Posts: 107
Please find a good tuturial on package at http://www.jarticles.com/package/package_eng.html


Being defeated is often a temporary condition. Giving up is what makes it permanent.
Edisandro Bessa
Ranch Hand

Joined: Jan 19, 2006
Posts: 584
Hey Man,

For sure this thread can help you.


"If someone asks you to do something you don't know how to, don't tell I don't know, tell I can learn instead." - Myself
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: problem while compiling
 
Similar Threads
help for HFSJ - CH 3 Page 84
help for HFSJ - CH 3 Page 84
chapter 3 "mini MVC"
chapter 3:package com.example.model does exist
HF Servlet and Java - MVC tutorial