The moose likes Beginning Java and the fly likes Unable to Compile Servlet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Unable to Compile Servlet" Watch "Unable to Compile Servlet" New topic

Unable to Compile Servlet

Senthil Kumar
Ranch Hand

Joined: Oct 14, 2007
Posts: 33
Hi All,
Iam trying to compile a simple servlet class in the command prompt.
but it is not able to recognize the servlet-api.jar which i hav set in the classpath as follows
set classpath=JBOSS_HOME/servlet/default/lib/servlet-api.jar;

Can anyone provide me a solution for the above the probs?
Thanks in advance
Richard Green
Ranch Hand

Joined: Aug 25, 2005
Posts: 536
set classpath=%JBOSS_HOME%/servlet/default/lib/servlet-api.jar;

MCSD, SCJP, SCWCD, SCBCD, SCJD (in progress - URLybird 1.2.1)
sudhir nim
Ranch Hand

Joined: Aug 29, 2007
Posts: 212

put ';' before appending servlet api to classpath

[Servlet tutorial] [Servlet 3.0 Cook Book]
Ben Souther

Joined: Dec 11, 2004
Posts: 13410

Hello Senthil Kumar,

I'm going to move this to our Java In General (Beginner) forum where javac and classpath issues are discussed.

You might want to look at this FAQ entry for tips on compiling servlets.

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
I agree. Here's the link:
subject: Unable to Compile Servlet
It's not a secret anymore!