Netbeans, the classes in lib directory are not available

From: vizlab (lianjian_at_caip.rutgers.edu)
Date: 07/19/04


Date: 19 Jul 2004 09:33:59 -0700

Hi, all:
    I felt very frustrated when I tried to execute a simple servlet in
a web module in netbeans3.6.
    This servlet, NewServlet.class, uses a class defined in a java
class, myjava.class.
    If I put myjava.class in the classes directory where
NewServlet.class is located, everything works fine.
    But if I make a jar file for myjava.class, say myjava.jar, and put
myjava.jar into the lib directory, NewServlet.class cannot find
myjava.class any more. Plus, the icon of myjava.class has a red
crossing sign, meaning this class is not valid.
    Why did this happen? How can I let myjava.class in myjava.jar be
valid and visible to my servlet?

Thanks a lot.

Best

Leon



Relevant Pages

  • Re: calling a servlet in tomcat
    ... 1.create a servlet (i made cookbook.SampleServlet.java that has doGet ... classes directory of tomcat ... urlpattern .But i want to invoke this by calling the Servlet name ...
    (comp.lang.java.programmer)
  • Re: Calling shell script from a Servlet.
    ... > When I try to do the same thing from a Servlet I get nothing. ... > because Tomcat should be able to find a directory where shell script ... Should I put a symbolic link somewhere in Tomcat home ... read / execute to bash, and possibly read and even execute on all the ...
    (comp.lang.java.programmer)
  • Re: Creating new thread from servlet
    ... I have a Java servlet running in Tomcat that is a form. ... into a database. ... time to execute, thus the submission of the form takes a long time. ... Start the threaded task and cache the thread-id or the runnable object or thread complete flag with some unique key ...
    (comp.lang.java.help)
  • Re: Need help w. NullPointerException.
    ... >i find myself in need of some help/assistance for a servlet that compiles okay, ... >but when I try to execute it in my browser I always get a ...
    (comp.lang.java.programmer)
  • Re: tomcat error..
    ... the error is, I find my way to the servlet and find line causing error, which is quite useful, but sometimes it doesn't tell you anything, like ... Tomcat is the servlet engine, but it doesn't execute JSPs, it compiles them into Java source, then compiles the Java source into bytecode, then it executes the bytecode. ... "log4j" in weblogic console when booting up weblogic.. ...
    (comp.lang.java.help)