GeeCON Prague 2014*
The moose likes JSP and the fly likes class problem Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » JSP
Bookmark "class problem" Watch "class problem" New topic

class problem

Ilja Smoli
Ranch Hand

Joined: Dec 02, 2001
Posts: 64
Hi there,
Im trying to install javaMail and JAF on my pc with win2k and tomcat 3.3.
problem is here:
1. I've puted javamail and jaf in c:\jdk\.
2. then I've puted CLASSPATH in enviroment variables like that: %CLASSPATH%;C:\jdk\javamail-1.3\mail.jar;C:\jdk\jaf-1.0.2\activation.jar;
And here is error i have:
org.apache.jasper.JasperException: Unable to compile C:\tomcat\work\DEFAULT\ROOT\ladu2\ Package javax.mail not found in import.
import javax.mail.*;
C:\tomcat\work\DEFAULT\ROOT\ladu2\ Package javax.mail.internet not found in import.
import javax.mail.internet.*;
Ok, i tryed to put activation.jar and mail.jar in tomcat/webapps/root/web-inf/lib folder
Still same error..
what im doing wrong? plz help

Joined: Jan 20, 2002
Posts: 17
plz mention one more thing, where u r setting the classpath for mail n jaf api. u need to set the classpath for tomcat server in tomcat.bat in bin folder.
try this one n reply soon.
Ilja Smoli
Ranch Hand

Joined: Dec 02, 2001
Posts: 64
thx for yr reply, but still not working...
I've done as u say, here is fragment of tomcat.bat:
set _CLASSPATH=%CLASSPATH%;C:\jdk\javamail-1.3\mail.jar;C:\jdk\jaf-1.0.2\activation.jar;
And jsp file:
<%@ page import="java.util.*"%>
<%@ page import="javax.mail.*"%>
<%@ page import="javax.mail.internet.*"%>
And also my guess: I have a context in tomcat/conf folder like:
<?xml version="1.0" encoding="ISO-8859-1"?>
<Context path=""
docBase="here is path to folder where jsp files are stored and executed through apache"
reloadable="true" >

So compiled classes appearing not in tomcat\webapps\root but in tomcat\work\default\root , and for instance there is no web-inf folder...
maybe it helps u to help me
Consider Paul's rocket mass heater.
subject: class problem