Thanks a lot steve :)
Let me add one more question please, is it possible to specify the starting
and ending index through which I would like to loop ?
like the original for loop for example. you can start at a specific index
and end at a specific index ?

I can try to figure out a way to make this indirectly using the sublist
method for example (i.e. regarding lists)..but is there a more direct wya ?

On Wed, Aug 24, 2011 at 4:09 PM, Steve Eynon <[email protected]
> wrote:

> Yeah, I believe this is a common gotcha...
>
> Don't use ${property expansions} in t:attributes.
>
> Try this:
>
> <t:loop source="reachabilityService.reachabilityReportIpk"
>
> Steve.
> --
> Steve Eynon
>
>
> On 24 August 2011 21:35, Muhammad Gelbana <[email protected]> wrote:
> > Oh sorry, here is the exception:
> >
> > org.apache.tapestry5.internal.services.RenderQueueException
> > Render queue error in BeginRender[Index:loop]: Failure writing parameter
> > 'value' of component Index:loop: Could not find a coercion from type
> > java.lang.String to type
> > com.skycomm.cth.services.reachability.ping.ReachabilitySummary.
> >
> > org.apache.tapestry5.ioc.util.UnknownValueException
> > Could not find a coercion from type java.lang.String to type
> > com.skycomm.cth.services.reachability.ping.ReachabilitySummary.
> >
> > Thanks..
> >
> >
> >
> > On Wed, Aug 24, 2011 at 3:30 PM, Muhammad Gelbana <[email protected]
> >wrote:
> >
> >> Hi all,
> >>
> >> I know this is a trivial matter but I've been trying to solve it for
> >> sometime now and I just can't figure out what am I doing wrong !!
> >> I have an Index.java class with this property:
> >>
> >> @Property
> >>     @Inject
> >>     private ReachabilityService reachabilityService;
> >>     @Property
> >>     private int reachabilityIndex;
> >>     @Property
> >>     private ReachabilitySummary reachabilitySummary;
> >>
> >> And a in it's .tml:
> >> <table>
> >>         <tr>
> >>             <t:loop
> source="${reachabilityService.reachabilityReportIpk}"
> >> value="reachabilitySummary" index="reachabilityIndex">
> >>                 <td>${reachabilityIndex} -
> >> ${reachabilitySummary.isEpUp}</td>
> >>             </t:loop>
> >>         </tr>
> >>     </table>
> >>
> >> The "reachabilityService.reachabilityReportIpk" method retruns a mock
> list
> >> that I create manually so it should not be a problem.
> >> The issue is that It keeps trying to convert the "reachabilitySummary"
> into
> >> a string or something !!!! I prefixed it with  "prop" although it's the
> >> default prefix, but no use !
> >>
> >> What am I doing wrong here ?
> >>
> >>
> >> --
> >> *Regards,*
> >> *Muhammad Gelbana
> >> Java Developer*
> >>
> >>
> >
> >
> > --
> > *Regards,*
> > *Muhammad Gelbana
> > Java Developer*
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


-- 
*Regards,*
*Muhammad Gelbana
Java Developer*

Reply via email to