Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

class path problem in package

 
jawwad ahmed
Ranch Hand
Posts: 179
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well i saved class file in the
c:\tomcat2\webapps\examples\web-inf\classes\filename.java
i set path
set classpath=c:\tomcat2\lib\servlet.jar
whan i make pakage pk and saved in classes folder
can anybody please tell the classpath of it.
 
Matthew X. Brown
Ranch Hand
Posts: 165
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use folder notation for your package.
Like this - if i'm referencing the com.sun.java.help.search package
D:\tomcat\webapps\examples\web-inf\classes\com\sun\java\help\search\
then all of my classes go here. Also-you put your .class files there-not your .java files. They need to be compiled already. Also-don't worry about jarring a file and putting it under the lib directory- these classes under the classes directory will be picked up the webserver automatically.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic