You are viewing a plain text version of this content. The canonical link for it is here.
Posted to adffaces-dev@incubator.apache.org by Piyush Hari <pi...@oracle.com> on 2006/09/15 03:30:31 UTC

table with commandButton

Hello,

Is it possible to contain a <tr:commandButton> within a <tr:table> ?

As per the documentation,  <tr:table> should have a <tr:column> as its immediate child and only certain types of components are supported as children inside a Column. Supported components include all components with no behaviour and most components that implement the EditableValueHolder or ActionSource interfaces.

I tried putting a commandButton within a column like this:
   
  <tr:table>
         <tr:column>
            <f:facet name="header">
               <tr:outputText value="Action"/>
            </f:facet>                
            <tr:commandButton id="commandButton1" text="Button1" />            
          </tr:column>
    </tr:table>  

...and it did not work. Please advise.

Regards,
Piyush


Re: table with commandButton

Posted by Mike Kienenberger <mk...@gmail.com>.
I don't actually work with ADFFaces/Trinidad, but commandButton must
implement ActionSource.

By the way, that definition includes almost everything :-)

These kinds of problems are generally due to using a request-scoped
bean attribute for your table's value attribute.   An easy test is to
make the bean session-scoped and see if that causes the problem to
disappear.   If so, you need to use t:saveState or the equivalent in
Trinidad to persist the bean across requests.

On 9/14/06, Piyush Hari <pi...@oracle.com> wrote:
> Hello,
>
> Is it possible to contain a <tr:commandButton> within a <tr:table> ?
>
> As per the documentation,  <tr:table> should have a <tr:column> as its immediate child and only certain types of components are supported as children inside a Column. Supported components include all components with no behaviour and most components that implement the EditableValueHolder or ActionSource interfaces.
>
> I tried putting a commandButton within a column like this:
>
>   <tr:table>
>          <tr:column>
>             <f:facet name="header">
>                <tr:outputText value="Action"/>
>             </f:facet>
>             <tr:commandButton id="commandButton1" text="Button1" />
>           </tr:column>
>     </tr:table>
>
> ...and it did not work. Please advise.
>
> Regards,
> Piyush
>
>
>