* tooy li(Gmail):

> I want to  create a custom page  to catch all error  , log these
> into db  and only show some  clear infomation into user.  i know
> set  something in  the application,  but how  can i  catch these
> error in my page?

So you want to handle the exception yourself?  Try this in your
Application:

@Override
protected IRequestCycleProcessor newRequestCycleProcessor() {
        return new WebRequestCycleProcessor() {
                @Override
                protected Page onRuntimeException(Page page, RuntimeException 
e) {
                        logErrorInDataBase(e);
                        return new MyExceptionPage();
                }
        };
}

You don't indicate which version of Wicket you're using, I assume
the latest in this code snippet.
-- 
     Jean-Baptiste Quenot
aka  John Banana   Qwerty
http://caraldi.com/jbq/

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Wicket-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wicket-user

Reply via email to