I decided to just put the exception in the session and just grab it from there.
Douglas On Mar 3, 2012, at 10:26 AM, vineet semwal wrote: > you should also do page.setStatelessHint(false) > > Page page=new ClientErrorPage(ex); > IPageProvider provider = new PageProvider(page); > page.setStatelessHint(false); > return new RenderPageRequestHandler(provider, RedirectPolicy.ALWAYS_REDIRECT); > > On Sat, Mar 3, 2012 at 8:23 PM, Douglas Ferguson <the...@gmail.com> wrote: >> Yeah Martin Grigorov recomended that I do just that: >> >>> WebPage exceptionPage = new NotifyUserOfException(ex); >>> IPageProvider provider = new PageProvider(page); >>> return new RenderPageRequestHandler(provider /*, >>> RenderPageRequestHandler.RedirectPolicy.XYZ */ ); >> >> >> But I finding that it throws away the page that I pass in and just uses the >> class object. >> I discovered this because I don't have a default constructor so it blows up >> on newInstance(). >> >> Douglas >> >> On Mar 3, 2012, at 1:36 AM, vineet semwal wrote: >> >>> i think scheduling is wrong in this usecase ,actually just overriding >>> onexception and returning your handler like you did before should have >>> worked but wait for some one else to respond if its not working >>> >>> On Sat, Mar 3, 2012 at 12:47 PM, Douglas Ferguson <the...@gmail.com> wrote: >>>> I tried overriding onExceptionRequestHandlerResolved but I can't get this >>>> to work. >>>> >>>> I'm still not getting my error page to load on errors. >>>> >>>> Douglas >>>> >>>> On Mar 3, 2012, at 12:36 AM, Douglas Ferguson wrote: >>>> >>>>> I mean "too many redirects" >>>>> >>>>> On Mar 3, 2012, at 12:36 AM, Douglas Ferguson wrote: >>>>> >>>>>> Causes an infinite loop. >>>>>> >>>>>> Douglas >>>>>> >>>>>> On Mar 3, 2012, at 12:20 AM, vineet semwal wrote: >>>>>> >>>>>>> i think you need to return the handler which you have scheduled >>>>>>> >>>>>>> On Sat, Mar 3, 2012 at 11:30 AM, Douglas Ferguson <the...@gmail.com> >>>>>>> wrote: >>>>>>>> onException() wants be to run a redirectHandler. do I just return null? >>>>>>>> >>>>>>>> >>>>>>>> On Mar 2, 2012, at 11:44 PM, vineet semwal wrote: >>>>>>>> >>>>>>>>> you need to do requestcycle.scheduleRequestHandlerAfterCurrent(new >>>>>>>>> RenderPageRequestHandler(provider, RedirectPolicy.ALWAYS_REDIRECT)); >>>>>>>>> >>>>>>>>> On Sat, Mar 3, 2012 at 10:53 AM, Douglas Ferguson <the...@gmail.com> >>>>>>>>> wrote: >>>>>>>>>> >>>>>>>>>> In migrating to wicket 1.5 from 1.4 I used this to redirect to my >>>>>>>>>> error page when an exception is thrown. >>>>>>>>>> But when I do this it is trying to instantiate a new copy of the >>>>>>>>>> page rather than using the one I pass in. >>>>>>>>>> >>>>>>>>>> IPageProvider provider = new PageProvider(new >>>>>>>>>> ClientErrorPage(ex)); >>>>>>>>>> return new RenderPageRequestHandler(provider, >>>>>>>>>> RedirectPolicy.ALWAYS_REDIRECT); >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>> -- >>>>>>>>> thank you, >>>>>>>>> >>>>>>>>> regards, >>>>>>>>> Vineet Semwal >>>>>>>>> >>>>>>>>> --------------------------------------------------------------------- >>>>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>>>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org >>>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> --------------------------------------------------------------------- >>>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org >>>>>>>> >>>>>>> >>>>>>> >>>>>>> >>>>>>> -- >>>>>>> thank you, >>>>>>> >>>>>>> regards, >>>>>>> Vineet Semwal >>>>>>> >>>>>>> --------------------------------------------------------------------- >>>>>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>>>>>> For additional commands, e-mail: users-h...@wicket.apache.org >>>>>>> >>>>>> >>>>> >>>> >>>> >>>> --------------------------------------------------------------------- >>>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>>> For additional commands, e-mail: users-h...@wicket.apache.org >>>> >>> >>> >>> >>> -- >>> thank you, >>> >>> regards, >>> Vineet Semwal >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >>> For additional commands, e-mail: users-h...@wicket.apache.org >>> >> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org >> For additional commands, e-mail: users-h...@wicket.apache.org >> > > > > -- > thank you, > > regards, > Vineet Semwal > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org > For additional commands, e-mail: users-h...@wicket.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org For additional commands, e-mail: users-h...@wicket.apache.org