-
How To Catch an exception in jsp which thrown from a jar file (4 messages)
- Posted by: Krishna Ammanabrolu
- Posted on: December 29 2006 10:49 EST
Please suggest me an approach to catch an Exception thrown from a jar file,and needs to be display in the jsp file. We are using j_security_check action which is provided by the web server(Jboss server) for login authentication. rigth now we are receiving either success or failure but we want to display specific type of exception like user name not found ,password wrong .How can we catch and display exceptions in jsp.Threaded Messages (4)
- Re: How To Catch an exception in jsp which thrown from a jar f by Anil Kumar Sadineni on January 01 2007 23:24 EST
- Re: How To Catch an exception in jsp which thrown from a jar f by Asdfg Zxcvb on January 02 2007 08:59 EST
-
Regarding catching exception thrown from a jar by Krishna Ammanabrolu on January 03 2007 12:07 EST
- Re: Regarding catching exception thrown from a jar by Jyothish John on January 06 2007 09:39 EST
-
Regarding catching exception thrown from a jar by Krishna Ammanabrolu on January 03 2007 12:07 EST
- Re: How To Catch an exception in jsp which thrown from a jar f by Asdfg Zxcvb on January 02 2007 08:59 EST
-
Re: How To Catch an exception in jsp which thrown from a jar f[ Go to top ]
- Posted by: Anil Kumar Sadineni
- Posted on: January 01 2007 23:24 EST
- in response to Krishna Ammanabrolu
The following link may help you http://jira.jboss.com/jira/browse/JBAS-2352 Thanks, Anil. -
Re: How To Catch an exception in jsp which thrown from a jar f[ Go to top ]
- Posted by: Asdfg Zxcvb
- Posted on: January 02 2007 08:59 EST
- in response to Anil Kumar Sadineni
Use a try catch block in your jsp code where exception is thrown. A jsp class can throw ServletException, IOException and RuntimeException and Also JspException. Try to catch and throw one of these depending on the exception kind. Else, catch them in custom tag classes. I wonder wats the link with jira.jboss.com got to do with the question. -
Regarding catching exception thrown from a jar[ Go to top ]
- Posted by: Krishna Ammanabrolu
- Posted on: January 03 2007 00:07 EST
- in response to Asdfg Zxcvb
Thanks for ur help. but the thing is we are not writing anything in the jsp.we need to display custom exceptions,we are thinking about where we need to store the exception to transfer this exception from jar file to jsp page.Again jsp not interacting with the jar file. there is a container provided servlet that will forward the jsp on which we need to display exception. can u explain a bit broadly how custom tag classes will be done. -
Re: Regarding catching exception thrown from a jar[ Go to top ]
- Posted by: Jyothish John
- Posted on: January 06 2007 09:39 EST
- in response to Krishna Ammanabrolu
Extend the Servlet;) and check for valid Data;) and throw your custom Exceptions on will;)