0 Replies Latest reply on Aug 17, 2011 10:14 AM by Roger Gilliar

    Keep horizontal positon of dataTable after sorting

    Roger Gilliar Newbie

      Hi,

       

      I implemented sorting on an extendedDataTable as shown in the RichFaces showcase. The problem I have is that the datatable alway scrolls back to the left. I would have expected that the datatable remembers it's horizontal position. The code looks something like this:

       

      <rich:extendedDataTable id="dataTable"

          rowKeyVar="index"

          selectionMode="single"

          selection="#{cc.attrs.controller.selection}"

          rowClasses="light-table-row,dark-table-row"

          value="#{cc.attrs.controller.listOfData}"

          var="data"

          rows="12">

          

          <rich:column id="cStatus">

              <f:facet name="header" id="headerStatus">

                  <a4j:commandLink

                          id="stateItem"

                          value="#{msgs.status}"

                          actionListener="#{cc.attrs.controller.sortAction}"

                          render="dataTable"/>

              </f:facet>

              <custom:warningField value="#{data.stateItem}" />

          </rich:column>

       

      Any idea how to keep the datatable from scrolling back to the leftmost position ?

       

      Regards

        Roger