| View previous topic :: View next topic |
| Author |
Message |
Richmason General User

Joined: 05 Sep 2007 Posts: 6
|
Posted: Wed Sep 05, 2007 12:30 pm Post subject: Reference to a cells background/fill color? |
|
|
How can I compare the background colors of two cells?
e.g. =IF(back_color(A1)=back_color(A2);YES;NO)
e.g. =backcolour(A1;A2)
When cell A1 and A2 are both red, cell B2 reads "YES" or "TRUE".
However, if cell A1 is red but A2 is blue, cell B2 reads "NO" or "FALSE". |
|
| Back to top |
|
 |
acknak Moderator


Joined: 13 Aug 2004 Posts: 4295 Location: ~ 40°N,75°W
|
Posted: Wed Sep 05, 2007 1:38 pm Post subject: |
|
|
As far as I know, it can't be done.
Calc is designed for the formatting (i.e. color) to be determined by the data in the cell, not the other way around. In other words, change the data in the cell, then use the distinct values to set the color, e.g. by conditional formatting. |
|
| Back to top |
|
 |
David Super User


Joined: 24 Oct 2003 Posts: 5668 Location: Canada
|
Posted: Wed Sep 05, 2007 6:39 pm Post subject: Re: Reference to a cells background/fill color? |
|
|
You can determine if a cell has a colour, but not which one [a CELL-function attribute.] 'Twould be nice though.
David. |
|
| Back to top |
|
 |
|