Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to change row color of table in vaadin

Tags:

vaadin

HI im working with vaadin,I have a table and im using the addItem Method to add items , what i want to do is at the moment of adding a new item i have to make some tests and set the color of the added row.

For example the resutlt of test is 1 then row color should be Red , and if the result is 2 row color should be green.

So any help how to do this ?

like image 815
aminedev Avatar asked Apr 24 '12 08:04

aminedev


1 Answers

You can do this with a CellStyleGenerator and apply it to all cells in one row. More about CellStyleGenerator here.

like image 188
nexus Avatar answered Nov 01 '22 15:11

nexus