please i need help here after successfully deploying and i tried to test the web app but the server displays this error and i dont know what the problem might be..

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


Generated servlet error:
[javac] C:\Sun\AppServer\domains\domain1\generated\jsp\j2ee-apps\customer\war-ic_war\org\apache\jsp\Authentication_jsp.java:30: 'try' without 'catch' or 'finally'
[javac]     try {
[javac]     ^



Generated servlet error:
[javac] C:\Sun\AppServer\domains\domain1\generated\jsp\j2ee-apps\customer\war-ic_war\org\apache\jsp\Authentication_jsp.java:60: 'else' without 'if'
[javac] else{
[javac] ^



Generated servlet error:
[javac] C:\Sun\AppServer\domains\domain1\generated\jsp\j2ee-apps\customer\war-ic_war\org\apache\jsp\Authentication_jsp.java:68: illegal start of type
[javac]     } catch (Throwable t) {
[javac]       ^



Generated servlet error:
[javac] C:\Sun\AppServer\domains\domain1\generated\jsp\j2ee-apps\customer\war-ic_war\org\apache\jsp\Authentication_jsp.java:78:  expected
[javac]   }
[javac]   ^



Generated servlet error:
[javac] C:\Sun\AppServer\domains\domain1\generated\jsp\j2ee-apps\customer\war-ic_war\org\apache\jsp\Authentication_jsp.java:79: 'class' or 'interface' expected
[javac] }
[javac] ^



Generated servlet error:
[javac] C:\Sun\AppServer\domains\domain1\generated\jsp\j2ee-apps\customer\war-ic_war\org\apache\jsp\Authentication_jsp.java:80: 'class' or 'interface' expected
[javac] ^
[javac] 6 errors



org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:88)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:337)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:429)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:489)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:468)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:456)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:516)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:307)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:251)
javax.servlet.http.HttpServlet.service(HttpServlet.java:860)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
java.security.AccessController.doPrivileged(Native Method)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)

note The full stack trace of the root cause is available in the Sun-Java-System/Application-Server logs.

Sun-Java-System/Application-Server

Edited 3 Years Ago by happygeek: fixed formatting

I think u are in the wrong forum, but your jsp file is giving the errors, teh first one tells u that u need a catch or finally when using the try statement.

Another thing u shouldnt be using those statements in a jsp file, put them in a servlet, jsp is only used for display purposes.

Well the first line says that Unable to compile class for JSP ,
Which quiet simply means that you have an syntax error in you JSP and from the type of errors displayed I think you have put an extra } in your code inside the try block.

This article has been dead for over six months. Start a new discussion instead.