File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

problem in compilation of servlet in apache-tomcat

 
Himanshu Daurbi
Greenhorn
Posts: 4
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello friends,
I am using apache-tomcat 5.5.17 and jdk 1.6 . I have already set path of jdk using environment variable. I am deploying a servlet on it after starting server. I have already made directory structure in desktop. I am compiling my program using statement in command prompt.

C:>cd Users\him\desktop\project //here is my directory structure
C:>javac - classpath \Users\him\applications\tomcat 5.5\common\lib\servlet-api.jar;classes:. classes src\com\example\web\myservlet.java

and I'm getting error like this----
javac : invalid flag: 5.5\common\lib\servlet-api.jar;classes:.


I'm waiting for your response and thanks in advance...........
 
Campbell Ritchie
Sheriff
Pie
Posts: 47293
52
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you got a space after the -?
Have you got a space before 5.5? If you need a space before 5.5, then the whole classpath should be enclosed in "quotes".
 
Himanshu Daurbi
Greenhorn
Posts: 4
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ritchie,
Thanks so much to you. My program is working correctly now.

Thanks & Regards,
Himanshu Daurbi
 
Campbell Ritchie
Sheriff
Pie
Posts: 47293
52
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
“You’re welcome”, and well done
 
Campbell Ritchie
Sheriff
Pie
Posts: 47293
52
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
. . . and welcome to the Ranch I hadn’t noticed you are new.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic