Re: [t4] rendering DirectLink from Java code (renderer)

2008-03-18 Thread Petri Wessman
e link. If I just create it as a POJO, I get a Tapestry exception when I try to use it: Exception: [EMAIL PROTECTED] container is null. So I probably need to attach it to the current page (or something)? Or is AbstractComponent the wrong way to proceed, here? //Petri > On Tue, Mar 18, 2008

[t4] rendering DirectLink from Java code (renderer)

2008-03-18 Thread Petri Wessman
Hello all, I have a new question. I'd need to generate a DirectLink-style link from inside Java code (render method); in other words, generate HTML that would duplicate the effect of this: link text from a Java code method which has access to a IMarkupWriter object (and the IPage, if needed). An

Re: T4: form input components inside a For loop

2008-02-29 Thread Petri Wessman
Pai911 wrote: > Put an InvokeListener component in the For > > when the rewinding occures, it will invoke the listener with each Iteration. > > In each iteration, the page property is stored with different value which > you can use > > The listener is like > > public void updateUser(IRequestCyc

Re: T4: form input components inside a For loop

2008-02-28 Thread Petri Wessman
e the input fields inside the For loop? That's doable, but results in some regrettable copy-paste since I need to do this edit thing on more than one page -- that's why I went the component route in the first place :/. //Petri > > On Thu, Feb 28, 2008 at 3:32 PM, Petri Wessman <[E

T4: form input components inside a For loop

2008-02-28 Thread Petri Wessman
Ok, I'm a bit stumped here. I'm using Tapestry 4.1.3, and I'm trying to use (sub)components which have form input fields inside a For loop. I have a list of items, initialized by a "calling" page, and one as placeholder for the current value, something like this: public abstract Foobar getCur

Re: [tapestry 4.0.2] how to do variable number of checkboxes?

2008-01-07 Thread Petri Wessman
Andreas Andreou wrote: Well, there are some options here... Try removing public abstract boolean getSomeValue(); and use public boolean getSomeValue() { // return the correct value using getCurrentListItem() } public void setSomeValue(boolean value) { // store the value using getCurrentListIte

Re: [tapestry 4.0.2] how to do variable number of checkboxes?

2008-01-07 Thread Petri Wessman
Petri Wessman wrote: As a simplified concrete example, I'd have something like this on the page: What goes in "???" ? Replying to myself here :). I just occurred to me that I could (naturally) store the "checked" value into the current line it

Re: [tapestry 4.0.2] how to do variable number of checkboxes?

2008-01-07 Thread Petri Wessman
As a simplified concrete example, I'd have something like this on the page: What goes in "???" ? Sorry if I'm missing something obvious here, but so far RTFM hasn't clued me in sufficiently :/. //Petri On Jan 7, 2008 1:31 PM, Petri Wessman <[EMAI

[tapestry 4.0.2] how to do variable number of checkboxes?

2008-01-07 Thread Petri Wessman
Hello all, using Tapestry 4.0.2 here (had some Javascript issues when trying to upgrade to 4.1.x, so putting off upgrading till I figure those out). Anyway, I'm now trying to implement a new functionality to our app and am a bit puzzled as to the best way to do it. What I want to do is have a