# How can I changing foreground colors from different column with configureCell on Power Table?

**URL:** <https://forum.inductiveautomation.com/t/how-can-i-changing-foreground-colors-from-different-column-with-configurecell-on-power-table/60062>\
**Category:** Ignition\
**Tags:** ignition80, ignition81\
**Created:** [May 26, 2022, 1:39pm UTC](https://forum.inductiveautomation.com/t/how-can-i-changing-foreground-colors-from-different-column-with-configurecell-on-power-table/60062 "2022-05-26T13:39:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Aybars.Urut](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/aybars.urut/32/32003_2.png) [@Aybars.Urut](https://forum.inductiveautomation.com/u/Aybars.Urut)\
**Post date:** [May 26, 2022, 1:39pm UTC](https://forum.inductiveautomation.com/t/how-can-i-changing-foreground-colors-from-different-column-with-configurecell-on-power-table/60062/1 "2022-05-26T13:39:45Z")

</div>

Hi there,

Correct me if Im wrong, I couldnt find similar example for this topic in forum.

I want to manage specific cells foreground colors reagarding to other cell value.

This is working for only zeroth column.

```auto
if (rowView % 2 == 0): 
	if (colView == 0 and value == 13):
		return {'foreground': 'white','background': self.Background_Colour}

```

This my example, please tell me whats wrong here?

```auto
if (rowView % 2 == 0): 
	if (colView == 0 and value == 13):
		if(colView == 1 or colView == 2 or colView == 4 or colView == 5 or colView == 6 or colView == 7 or colView == 8):
				return {'foreground': 'white','background': self.Background_Colour}

```

If colView = 0 and its value = 13, i want to manage foreground color of colView = (1,2,4,5,6), not colView=0

Thank in advance.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [May 26, 2022, 3:12pm UTC](https://forum.inductiveautomation.com/t/how-can-i-changing-foreground-colors-from-different-column-with-configurecell-on-power-table/60062/2 "2022-05-26T15:12:57Z")

</div>

You need to understand how `configureCell` works.

It is invoked _for each cell_, every time the table needs to be redrawn.  
Any logic involving _other_ cells must be done by retrieving those cell values manually. You can’t _tell_ another cell what color it should be; instead, when you are in a particular column, you must _check_ the other cell(s) for your condition.

An additional point of caution: Do _nothing_ expensive, such as a tag read or DB read, in `configureCell`, or you will ruin the responsiveness of your client. It’s safe to read from properties, and that’s about it.

---

<div class="post-metadata">

**Author:** ![Aybars.Urut](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/aybars.urut/32/32003_2.png) [@Aybars.Urut](https://forum.inductiveautomation.com/u/Aybars.Urut)\
**Post date:** [May 26, 2022, 3:25pm UTC](https://forum.inductiveautomation.com/t/how-can-i-changing-foreground-colors-from-different-column-with-configurecell-on-power-table/60062/3 "2022-05-26T15:25:05Z")

</div>

Oh, I see.

Thank you for your reply.
