0 Replies Latest reply on Oct 14, 2011 2:29 PM by Hauke Gulich

    rich:dataTable onrowclick understanding with richfaces 4

    Hauke Gulich Newbie

      Hello everyone,

       

      can somebody give me a hint on how to use the onrowclick attribute at rich:dataTable?

      What I want is the index from my list I clicked on. I tought I could just put an integer property on my backing bean and assign that within the onrowclick attribute, but that isn't working:

       

       

      {code}<rich:dataTable value="#{customer.listing}" onrowclick="#{customer.activeCustomer}"{code}

       

      With the extendedDataTable I got that working with this

       

       

      {code}

      <rich:extendedDataTable value="#{customer.listing}" var="customer" width="100%" id="customerList" columns="4" selection="#{customer.selectedCustomer}">

              <a4j:ajax execute="@form" event="selectionchange" listener="#{customer.selectingChange}" render="testingID" />

      {code}

       

      But with the extendedDataTable I have problems defining the width of each column be default. All columns are always 100px width. If I use columnClasses it will be ignored and if I put a style="width:200" at each rich:column, it will be ignored as well.

       

      Does anyone has some information for me?

       

       

      PS.: I am using richfaces 4 !

       

      Thanks,

      Hauke