how to include a user java file into a jsp page

Discussion in 'Software' started by gaurav_kant, Oct 5, 2007.

  1. gaurav_kant


    Sep 26, 2007
    Likes Received:

    in a jsp program,
    i have a in src folder. and arose.jsp is in main project folder(outside WEB-INF folder). Tramp.class is placed in WEB-INF/classes/ReadAndPrintXMLFile.class .

    now in .java file, 1 public static fun() named function exists. i m calling this function in my jsp page inside scriptlet. like this




    class paths & all i think right. but i dont know y this error is comming

    An error occurred at line: 26 in the jsp file: /ShowFile.jsp
    ReadAndPrintXMLFile cannot be resolved
    23: <th width="100">Status</th>
    24: <%
    25: //ReadAndPrintXMLFile fl=null;
    26: Vector;
    27: Iterator itr= sup.iterator();
    28: boolean change=false;
    29: while(itr.hasNext()) {

    at org.apache.jasper.compiler.DefaultErrorHandler.javacError(
    at org.apache.jasper.compiler.ErrorDispatcher.javacError(
    at org.apache.jasper.compiler.JDTCompiler.generateClass(
    at org.apache.jasper.compiler.Compiler.compile(
    at org.apache.jasper.compiler.Compiler.compile(
    at org.apache.jasper.compiler.Compiler.compile(
    at org.apache.jasper.JspCompilationContext.compile(
    at org.apache.jasper.servlet.JspServletWrapper.service(
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(
    at org.apache.jasper.servlet.JspServlet.service(
    at javax.servlet.http.HttpServlet.service(
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(
    at org.apache.catalina.core.StandardWrapperValve.invoke(
    at org.apache.catalina.core.StandardContextValve.invoke(
    at org.apache.catalina.core.StandardHostValve.invoke(
    at org.apache.catalina.valves.ErrorReportValve.invoke(
    at org.apache.catalina.core.StandardEngineValve.invoke(
    at org.apache.catalina.connector.CoyoteAdapter.service(
    at org.apache.coyote.http11.Http11Processor.process(
    at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(
    at org.apache.tomcat.util.threads.ThreadPool$
    at Source)

    :bored: please help me out
    gaurav_kant, Oct 5, 2007
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.