7 Replies Latest reply on Apr 9, 2009 7:17 AM by nimo stephan

    DataTable Selected Row

    Dov Frankel Newbie

      I'm having a very annoying problem with the rich:dataTable I'm using in my Seam app. I'm highlighting the row the user clicks on, and can successfully update the row's background color, but can't change the foreground color. The line commented out below has no effect. I'm using an a4j:support to call a javascript function onRowClick for the datatable, using the following code (found here, at 1.70: http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/docs/devguide/en/faq/faq.html)

       var oldRow;
       function changeColor( row )
       {
       if( oldRow != undefined ) {
       oldRow.style.backgroundColor = "#FFFFFF";
       }
      
       /* row.style.color = "red"; */
       row.style.backgroundColor = "#0090FF";
       oldRow = row;
       }