# Table Component Color

**URL:** <https://forum.inductiveautomation.com/t/table-component-color/1785>\
**Category:** Ignition\
**Created:** [April 26, 2010, 7:40pm UTC](https://forum.inductiveautomation.com/t/table-component-color/1785 "2010-04-26T19:40:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![JordanCClark](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jordancclark/32/83362_2.png) [@JordanCClark](https://forum.inductiveautomation.com/u/JordanCClark)\
**Post date:** [April 26, 2010, 7:40pm UTC](https://forum.inductiveautomation.com/t/table-component-color/1785/1 "2010-04-26T19:40:12Z")

</div>

Is there any way to change the color of the unfilled portion of a table component?  
 ![](https://us1.discourse-cdn.com/inductiveautomation/original/1X/d9b955fec26498cc4cbaebc30a7fd7683d68d1a2.jpg)

---

<div class="post-metadata">

**Author:** ![JordanCClark](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jordancclark/32/83362_2.png) [@JordanCClark](https://forum.inductiveautomation.com/u/JordanCClark)\
**Post date:** [April 28, 2010, 3:28pm UTC](https://forum.inductiveautomation.com/t/table-component-color/1785/2 "2010-04-28T15:28:44Z")

</div>

bump… only 'cause it’s been a couple of days…

---

<div class="post-metadata">

**Author:** ![Travis.Cox](https://avatars.discourse-cdn.com/v4/letter/t/b9bd4f/32.png) [@Travis.Cox](https://forum.inductiveautomation.com/u/Travis.Cox)\
**Post date:** [April 28, 2010, 6:26pm UTC](https://forum.inductiveautomation.com/t/table-component-color/1785/3 "2010-04-28T18:26:12Z")

</div>

Unfortunately, that background color is not currently exposed on the component. However, you can add a simple script to change the color. Right click on the component and select Event Handlers. Click on propertyChange and add the folllowing script:

`if event.propertyName == "data":
	from java.awt import Color
	table = event.source.parent.getComponent('Table')
	table.getViewport().setBackground(Color(0,255,0,255))`This script will set the color whenever the data property changes. We will add this property to the component and it will be there in the next release.

---

<div class="post-metadata">

**Author:** ![JordanCClark](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/jordancclark/32/83362_2.png) [@JordanCClark](https://forum.inductiveautomation.com/u/JordanCClark)\
**Post date:** [April 28, 2010, 7:38pm UTC](https://forum.inductiveautomation.com/t/table-component-color/1785/4 "2010-04-28T19:38:43Z")

</div>

Cool! Thanks, Travis!
