Also, note that you will probably have to mark the "aluno" attribute in the
User page as persistent (e.g. with @Persist annotation), or set it as the
page's activation context. Otherwise, whatever you set in setAluno will get
wiped out when T5 redirects to the @User page.

Cheers,

Alex K

On Fri, Sep 5, 2008 at 9:15 AM, Thiago H. de Paula Figueiredo <
[EMAIL PROTECTED]> wrote:

> Em Fri, 05 Sep 2008 09:17:09 -0300, Alex Florentino <
> [EMAIL PROTECTED]> escreveu:
>
>     public Object onSuccess() {
>>       my.package.tranc.pages.User userPage = new
>> my.package.tranc.pages.User();
>>       userPage.setAluno(classmate);
>>       return userPage;
>>    }
>>
>
> @Inject
> private User userPage;
>
>     public Object onSuccess() {
>        userPage.setAluno(classmate);
>        return userPage;
>     }
>
> }
>
> One common pitfall for anyone learning Tapestry 5 is that you cannot
> instatiate pages and components objects by yourself.
>
> Thiago
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to