• Post Reply Bookmark Topic Watch Topic
  • New Topic

ERROR mesage

 
Jeff Dube
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all
This is really strange...
When i submitt my form, i have the following error:
Internal Servlet Error:
org.apache.jasper.JasperException: Unable to compile class for JSPG:\Java\JSP\jakarta-tomcat-3.2.2\work\localhost_8080%2Fexamples\_0002fjsp_0002fCFTC_0002fShowValues_0002ejspShowValues_jsp_2.java:285: 'catch' without 'try'.
} catch (Exception ex) {
^
G:\Java\JSP\jakarta-tomcat-3.2.2\work\localhost_8080%2Fexamples\_0002fjsp_0002fCFTC_0002fShowValues_0002ejspShowValues_jsp_2.java:294: '}' expected.
}
^
G:\Java\JSP\jakarta-tomcat-3.2.2\work\localhost_8080%2Fexamples\_0002fjsp_0002fCFTC_0002fShowValues_0002ejspShowValues_jsp_2.java:295: 'try' without 'catch' or 'finally'.
^
3 errors

But guess what? I don't have any try or catch within my code........ !!!
Why can this happen. My code contains 2 pages. The first one is a normal html page with <form> tags and there is no jsp tags.
The second is the called file that process the informstion and this is the source for these error but i don't have any try or catch. I can print the code if you need it...
Thanks
Jeff
 
Steve Chernyak
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This is just an idea.
Maybe one of your brackets is not balanced in your jsp.
When the jsp engine tries to compile the jsp into a .class file it first creates a .java file, and as part of this procedure wraps all of the code inside of a try/catch block, but when it goes to compile it the compiler complains about the try without catch block.
 
Jeff Dube
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much.
That was right there was a missing brackets in my loop. Thanks a lot.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!