• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

setting classpath for servlet-api.jar

 
Kondapally Ashwin
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Please advise how I can set the classpath for servlet-api.jar.

I tried out setting the classpath in environment variables and also tried out setting the classpath in command prompt by entering the command set CLASSPATH = .;C:\Tomcat5.5\common\lib\servlet-api.jar. But I am still getting the same errors -cannot find symbol...
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64959
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you talking about during compilation or execution?
 
Kondapally Ashwin
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I was able to compile the file by using the command javac -classpath C:\Tomcat5.5\lib\servlet-api.jar HelloServlet.java.

But I couldn't compile after separately setting the classpath in environment variables as well as setting classpath in command.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic