docs/versioned_docs/version-2.62.0/how-to/access-cellvalue-rowdata.md
This guide shows how to change the text color and background color of certain cells in a Table component based on specific conditions.
</div> <div style={{paddingTop:'24px', paddingBottom:'24px'}}>+ Add button.https://fakestoreapi.com/products
{{queries.restapi1.data}}
category column, paste the below code under Text Color to dynamically change the text color based on the value of the cell:{{cellValue == 'electronics' ? 'red' : 'green'}}
Now, if the cell value is electronics, the text color will be red; otherwise, it will be green.
<i>You can use also Hex color codes for more color options.</i>
</div> <div style={{paddingTop:'24px', paddingBottom:'24px'}}>symbol column, paste the below code:{{rowData.price < 100? 'yellow': 'white'}}
The rowData identifier can be utilized to reference values from any column within the Table component.
Now if the value in the price column is lesser than 100, the cell background color will be yellow or else it will be white.
<div style={{textAlign: 'center'}}> </div>You can use the above methods to change the text and background colors of a cell dynamically.
</div>