I agree this belongs to the user mailing lists, but since we are already
here...

The code you propose would iterate over #{page.columns} but using each
elements as a row. I think what sebastian wants is to dinamically set the
table's columns (at build time) to later populate it with rows.

I have no idea why the classCast exception is happening, though.

Regards.

2006/8/28, Simon Lessard <[EMAIL PROTECTED]>:

Not sure since I don't use Facelets what often. However, using c:foreach
with a JSF application is never a good idea unless you're using JSF
1.2.Inyour case I would rather use something like:

<af:table value="#{page.columns}" var="col">
   <af:column ...>
</af:table>


Regards,

~ Simon

p.s. I think this kind of discussion belong to the user mailing list.

On 8/28/06, [EMAIL PROTECTED] <
[EMAIL PROTECTED]> wrote:
>
> I have the same Exception if I do something like this:
>
> <af:table ...>
>   <c:forEach var="col" items="#{page.columns}">
>      <af:column ...>
>   </c:forEach>
> </af:table>
>
> Any idea?
>
> Thanks,
> Sebastian
>
> > Hi!
> >
> > I don't know whether the following is a problem in Trinidad or in
> > Facelets, so I start a new topic here, even though this is related to
my
> > other posting "Throw explanatory exception in PanelTabbedRenderer for
> > wrong typed childs?".
> >
> > When I try to use a binding="#{someBean.someSetter}" in a
tr:panelTabbed
> > tag there is not one child returned by component.getChildren() in
> > PanelTabbedRenderer but seven. First child is a
> > com.sun.facelets.compiler.UIInstructions so we get a
ClassCastException.
> I
> > don't know whether it is ok for Facelets to insert these
UIInstructions
> > and PanelTabbedRenderer should cope with them or perhaps Facelets is
> doing
> > wrong here. Or maybe I do something real stupid?
> >
> > Any pointers welcome...
> >
> > Thanks,
> > Thorsten
> >
> >
> >
> > 7 child's:
> > -------------
> >       <tr:panelTabbed position="both"
> > binding="#{sammelgruppenDetailView.panelTabbed}" >
> >               <tr:showDetailItem text="testTab">
> >                       <tr:outputText value="testText"></tr:outputText>
> >               </tr:showDetailItem>
> >       </tr:panelTabbed>
> > -------------
> >
> >
> > 1 child:
> > -------------
> >       <tr:panelTabbed position="both" >
> >               <tr:showDetailItem text="testTab">
> >                       <tr:outputText value="testText"></tr:outputText>
> >               </tr:showDetailItem>
> >       </tr:panelTabbed>
> > -------------
> >
> >
>
>
>


Reply via email to