| Author |
Compiler error!
|
gurneeraj singh
Ranch Hand
Joined: Mar 19, 2008
Posts: 80
|
|
When I am trying to compile code on page no. 84 of HFSJ 2nd edition. I am getting compiler error on import statement (import com.example.model.* stating package com.example.model doesnot exist. I have made the deployment and development envoirnment as per the directions given in the book. I have also put the BeerExpert.class file in the src\com\example\model directory. I am using windows operating system.
|
SCJP 5.0 93%<br /> <br />SCWCD 5.0 97 %
|
 |
Amit M Tank
Ranch Hand
Joined: Mar 28, 2004
Posts: 257
|
|
|
How are you compiling your class? Are you using some IDE or you are using command line?
|
Amit Tank
Linked In
|
 |
gurneeraj singh
Ranch Hand
Joined: Mar 19, 2008
Posts: 80
|
|
|
I am using command-line to compile this class.
|
 |
Garlapati Ravi
Ranch Hand
Joined: Mar 05, 2008
Posts: 168
|
|
every one who visits this site may not be using HFSJ right ? please try to post the code as well if possible
|
Ravi Kumar
SCWCD 5 - 89%, SCJP 1.4 - 90%
|
 |
Amit M Tank
Ranch Hand
Joined: Mar 28, 2004
Posts: 257
|
|
When you are using the command line. what is the base directory from where you are running the javac? Make sure that you are in the /src dir when using javac option. I would recommend you to use eclipse Id/Ant Script to compile your code. It makes things easier. However, compiling it from command line should not be a problem if you are doing it the right way.
|
 |
 |
|
|
subject: Compiler error!
|
|
|