Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Java > Java and JDK > JSP Basics
|
JSP Basics Beginning-level questions on JSP. More advanced coders should post to Pro JSP.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the JSP Basics section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 23rd, 2004, 03:35 PM
Registered User
 
Join Date: Feb 2004
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Error on throwing_exception.html example, Chapter

Hi,

When I try the throwing_exception.html example on Chapter 9, I recieve the next error message.

org.apache.jasper.JasperException: JSP Class cannot be compiled.

No Java compiler was found to compile the generated source for the JSP.
This can usually be solved by copying manually $JAVA_HOME/lib/tools.jar from the JDK
to the common/lib directory of the Tomcat server, followed by a Tomcat restart.
If using an alternate Java compiler, please check its installation and access path.

    org.apache.jasper.compiler.DefaultErrorHandler.jav acError(DefaultErrorHandler.java:128)
    org.apache.jasper.compiler.ErrorDispatcher.javacEr ror(ErrorDispatcher.java:348)
    org.apache.jasper.compiler.Compiler.generateClass( Compiler.java:415)
    org.apache.jasper.compiler.Compiler.compile(Compil er.java:455)
    org.apache.jasper.compiler.Compiler.compile(Compil er.java:439)
    org.apache.jasper.JspCompilationContext.compile(Js pCompilationContext.java:555)
    org.apache.jasper.servlet.JspServletWrapper.servic e(JspServletWrapper.java:300)
    org.apache.jasper.servlet.JspServlet.serviceJspFil e(JspServlet.java:293)
    org.apache.jasper.servlet.JspServlet.service(JspSe rvlet.java:240)
    javax.servlet.http.HttpServlet.service(HttpServlet .java:856)


Loking at the tomcat logs I find the next message

23-feb-2004 13:29:48 org.apache.jasper.compiler.Compiler generateClass
GRAVE: Error compiling file: C:\jwsdp-1.3\work\Catalina\localhost\begjsp-ch09\org\apache\jsp\web\throwing_005fexception_jsp .java [javac] Compiling 1 source file
    [javac] C:\jwsdp-1.3\work\Catalina\localhost\begjsp-ch09\org\apache\jsp\web\throwing_005fexception_jsp .java:83: handlePageException(java.lang.Exception) in javax.servlet.jsp.PageContext cannot be applied to (java.lang.Throwable)
    [javac] if (pageContext != null) pageContext.handlePageException(t);
    [javac] ^
    [javac] 1 error

What can be wrong?

TIA

Jesus Gutierrez.





Similar Threads
Thread Thread Starter Forum Replies Last Post
RE: Chapter 5 input.html Error MissingSourceFile about2flip BOOK: Beginning Ruby on Rails 1 April 1st, 2008 10:35 PM
question regarding multi-column.html of chapter 2 mikeni1225 BOOK: CSS Instant Results 9 July 2nd, 2007 06:24 PM
Chapter 5 example5-2 and 5-3.html ericfields6483 BOOK: Beginning CSS: Cascading Style Sheets for Web Design ISBN: 978-0-7645-7642-3 5 May 23rd, 2006 01:26 PM
Chapter 2 HTML Henrik07 BOOK: Professional Ajax ISBN: 978-0-471-77778-6 3 March 13th, 2006 10:35 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.