File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes Unable to compile servelt-files. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "Unable to compile servelt-files." Watch "Unable to compile servelt-files." New topic

Unable to compile servelt-files.

Sebastian Green
Ranch Hand

Joined: Jan 30, 2004
Posts: 136
Hello, Im trying to compile But Igot errors on simple lines such as "import javax.servlet.*;" I belive that Im missing a jar-file clalled "servlets.jar" I have 2 java-dirs, "C:\Java\j2sdk1.4.1_03" & "C:\Program\Java\j2re1.4.1_03". But none of theme contains servlets.jar. Do I need j2ee or something more? My compiling error is: cannot resolve symbol.

/ Sebastian<br />No blog, No homepage, No life?
Billybob Marshall
Ranch Hand

Joined: Jan 27, 2004
Posts: 202
Originally posted by Mr Scam:
Do I need j2ee

Absolutely. You need a J2EE implementation, which will contain a jar containing the needed classes. Depending on which J2EE implementation you get (Tomcat, Weblogic, etc), it may or may not be named 'servlet.jar'.
Sebastian Green
Ranch Hand

Joined: Jan 30, 2004
Posts: 136
okej, Im off to dl it! Thanks for your reply!
Ko Ko Naing
Ranch Hand

Joined: Jun 08, 2002
Posts: 3178
Welcome to the Ranch!!!
I guess u might need to have a look at the naming policy of the Ranch.
U can change ur display name here.

Co-author of SCMAD Exam Guide, Author of JMADPlus
Sebastian Green
Ranch Hand

Joined: Jan 30, 2004
Posts: 136
Sorry mate..
Ben Dover
Ranch Hand

Joined: Jan 30, 2004
Posts: 91
Hi Sebastian,
Your best bet is to download the Tomcat-5 Servlet container, it contains a "sevlet.jar" file you can place in your path when compiling. Read the Tomcat docs re configuring the web.xml file, assembling your web app, deploying it, and then running it. Its a bit of a learning curve but once you have done it a few times it becomes second nature.
[ January 31, 2004: Message edited by: Louis M@lenica ]
Alexis Sumalpong

Joined: Jan 06, 2004
Posts: 13
The easiest way is to use and IDE that is meant for web app development. It should have all the libraries needed. For Tomcat, use this simple IDE

I agree. Here's the link:
subject: Unable to compile servelt-files.
It's not a secret anymore!