Newgro wrote:
>
> is there a wicket way for handling exceptions? I call my beans from my
> controller which manages the wicket-view (Panel, Page ...). Some
> exceptions i
> want to handle in the controller. But sometimes there are NPEs or IAEs. I
> would like to send them all to an error page, but without handling the
> exception. Is wicket presenting automatically a not handled exception?
>
This is done automatically in deployment mode. In development mode, you can
enable it like:
public class MyApp extends WebApplication {
protected void init() {
getExceptionSettings().setUnexpectedExceptionDisplay(
IExceptionSettings.SHOW_INTERNAL_ERROR_PAGE);
}
}
This will display wicket's internal error page. If you need to provide your
own
page, try:
getApplicationSettings().setInternalErrorPage(MyErrorPage.class);
--
View this message in context:
http://www.nabble.com/Howto-handle-exceptions--tf4498352.html#a12834389
Sent from the Wicket - User mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]