• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

urgent help needed

 
Smarter Shah
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
PLease help me...
i can run all the core java programs.had installed jdk 1.5.06.
then i had installed j2ee 1.4 setted the path variable to dir/lib/j2ee.rar
but still whenever i try to compile the program i recieve error similar to below one:

C:\james2\james2>javac addrec.java
addrec.java:72: package javax.servlet does not exist
import javax.servlet.*;
^
addrec.java:73: package javax.servlet.http does not exist
import javax.servlet.http.*;
^
addrec.java:75: cannot find symbol
symbol: class HttpServlet
public class addrec extends HttpServlet
^
addrec.java:77: cannot find symbol
symbol : class HttpServletRequest
location: class addrec
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException
^
addrec.java:77: cannot find symbol
symbol : class HttpServletResponse
location: class addrec
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException
^
addrec.java:77: cannot find symbol
symbol : class ServletException
location: class addrec
public void doGet(HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException

^
6 errors

please help me with this...
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to JavaRanch!

In an effort to help you get the most from our forums, we've compiled a
list of tips for asking questions here. You can find the list in our
FAQ section here.
In particular, please see UseAMeaningfulSubjectLine
and
EaseUp.


Again, welcome to JavaRanch and good luck with your question.
-Ben
 
Dave Wingate
Ranch Hand
Posts: 262
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does your classpath variable point to j2ee.rar? I've not worked with .rar files, but if the class against which you need to compile (e.g. HttpServletRequest) is located in that .rar file, I imagine you'll need to make sure it's included in your classpath (not your path).
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic