*
The moose likes Beginning Java and the fly likes Unable to complie 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 » Java » Beginning Java
Bookmark "Unable to complie" Watch "Unable to complie" New topic
Author

Unable to complie

hemant chaudhary
Greenhorn

Joined: Feb 22, 2007
Posts: 20
using this command :

javac -classpath "C:\Program Files\Apache Software Foundation\apache-tomcat-6.0.13\lib\servlet-api.jar":classes:. -d classes src\com\NameSelect.java

Errors I am getting like this:

e.g. :

src\com\NameSelect.java:3: package javax.servlet does not exist
import javax.servlet.*;

As far as I know everything is correct in path. I have installed new tomcat and servlet-api.jar is there in lib.

Please suggest a solution.
hemant chaudhary
Greenhorn

Joined: Feb 22, 2007
Posts: 20
sorry to bother you people ...corrected the mistake.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41155
    
  45
Try enclosing the complete classpath in double quotes, and not just part of it. Also, since you're on Windows, the delimiter that separates classpath entries is ";", not ":" (that's for Unix-like operating systems).


Ping & DNS - my free Android networking tools app
 
 
subject: Unable to complie
 
Similar Threads
Tomcat 6 - getting started
Help who compiled MVC from HF Servlet book
compiler error - package javax.servlet does not exists
Need help in compiling servlet
Including multiple JARs in javac -classpath