What Thiago is saying, you can just return the page (class or instance) if you changed the return type: @OnEvent(value = EventConstants.ACTIVATE) public Object initPage(Object[] parameters) throws IOException{ .... if(something goes wrong) { return MyErrorPage.class; }
Kalle On Thu, Mar 8, 2012 at 8:03 AM, Thiago H. de Paula Figueiredo <thiag...@gmail.com> wrote: > On Thu, 08 Mar 2012 12:53:26 -0300, Javix <s.camb...@gmail.com> wrote: > >> I don't really know, the method signature was defined as void that's why >> I'm asking. And as it is void, in java these methods can not return >> anything. > > > Unless this method is overriding another one, just change its return type > and do the right thing. ;) Using Response.sendRedirect() isn't very > Tapestry-ish. :) > > > -- > Thiago H. de Paula Figueiredo > Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and > instructor > Owner, Ars Machina Tecnologia da Informação Ltda. > http://www.arsmachina.com.br > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org > For additional commands, e-mail: users-h...@tapestry.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org For additional commands, e-mail: users-h...@tapestry.apache.org