JSP problem with classpath and class instantiation ...

D

d wood

I am working with Tomcat5 server and a simple JSP example that can be
found at www.jsptut.com/Forms.jsp, and am having a problem with the
visibility of a class (UserData.class).

The class cannot be found by the JSP SaveName_jsp.java when attempting
to compile it.

The directory containing file UserData.class is in the classpath,
which I have tested by instantiating it from another class in another
directory.

My question is: I have added the directory containing UserData.class
to my classpath under the directory
C:\Tomcat5\jakarta-tomcat-5\common\classes. The SaveName_jsp.java
compilation "cannot resolve symbol" UserData.

I have no problem instantiating UserData from another java class based
on existence in the classpath.

Any thoughts? Is more info needed?

Thanks!
 
C

Christophe Vanfleteren

d said:
I am working with Tomcat5 server and a simple JSP example that can be
found at www.jsptut.com/Forms.jsp, and am having a problem with the
visibility of a class (UserData.class).

The class cannot be found by the JSP SaveName_jsp.java when attempting
to compile it.

The directory containing file UserData.class is in the classpath,
which I have tested by instantiating it from another class in another
directory.

My question is: I have added the directory containing UserData.class
to my classpath under the directory
C:\Tomcat5\jakarta-tomcat-5\common\classes. The SaveName_jsp.java
compilation "cannot resolve symbol" UserData.

I have no problem instantiating UserData from another java class based
on existence in the classpath.

Any thoughts? Is more info needed?

Thanks!

Put UserData in a proper package.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top