> I defined a class MyServletContextListener where I use exceptions
> for example:
>
> public void contextInitialized(ServletContextEvent arg0)
> {
> s_context = arg0.getServletContext();
> try
> {
> ...
> }
> catch (ExInvalidUserName ex)
> {
> ??
> }
> catch (ExInvalidPassword ex)
> {
> ??
> }
> catch (ExInvalidSessionId ex)
> {
> ??
> }
> }
>
> In the web.xml I defined the following elements:
>
> <error-page>
>
> <exception-type>org.omg.CORBA.UserException.ExInvalidUserName
> </exception-type>
> <location>/errorPage.jsp</location>
> </error-page>
> <error-page>
>
> <exception-type>org.omg.CORBA.UserException.ExInvalidPassword
> </exception-type>
> <location>/errorPage.jsp</location>
> </error-page>
> <error-page>
>
> <exception-type>org.omg.CORBA.UserException.ExInvalidSessionId
> </exception-type>
> <location>/errorPage.jsp</location>
> </error-page>
>
> The error message displayed in the errorPage.jsp file depends on the
> exception.
> How does it works ? Where do I specify the error message associated
> to each specific exception ?
> in the following lines ?
>
> catch (ExInvalidUserName ex)
> {
> // Specify the error message to display ???
> }
>
> Has someone an exxample of a JSP page that allows to display
> exception error ?
>
> Thanks a lot for you help,
> Sandra
>
>
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>