tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sachin Chowdhary" <csac...@pisoftek.com>
Subject bean with jsp
Date Wed, 05 Feb 2003 12:09:07 GMT

I am trying to use a class by using useBean tag in jsp but i am not able to
do it so remove all coding and just using import class name syntax but still
i am not able to do that on tomcat4.1.18 .so what i am doing wrong

can you suggest me


C:\Program Files\Apache Group\Tomcat 4.1\webapps\examples\jsp
<%@ page import="MyClass" %>

<html>
    <body>
        Meet a Bean!
   </body>
</html>

//MyClass.java


C:\Program Files\Apache Group\Tomcat 4.1\webapps\examples\WEB-INF\classes
public class MyClass
{
 public String val;
}



HTTP Status 500 -

type Exception report
message
description The server encountered an internal error () that prevented it
from fulfilling this request.
exception
org.apache.jasper.JasperException: Unable to compile class for JSP

An error occurred at line: -1 in the jsp file: null

Generated servlet error:
    [javac] Compiling 1 source file

C:\Program Files\Apache Group\Tomcat
4.1\work\Standalone\localhost\examples\jsp\MyJsp_jsp.java:7: '.' expected
import MyClass;
              ^
1 error




---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message