Forum Discussion
rekkandevar
Sep 12, 2019Copper Contributor
How to color a cell based directly on a cell value
On mobile bc my internet isn't working today
How do I color a cell based not on its statistical relationship with other cells, but directly on its value? In particular I have a series of RGB values separated by channel and I'd like to include a sample of the color in question by the table.
How do I color a cell based not on its statistical relationship with other cells, but directly on its value? In particular I have a series of RGB values separated by channel and I'd like to include a sample of the color in question by the table.
4 Replies
Hello rekkandevar ,
You can use conditional formatting to set the color of a cell based on a value.
If, however, you want to use the current value of the cell to set the fill color to the equivalent RGB , then that is not possible with conditional formatting or with any worksheet technique. That would require VBA.
Can you post an example of the values your cells would have? RGB typically consists of three numeric values, not just one number, so I'd need to know how you store the RGB values in the cells.
- rekkandevarCopper ContributorIt's three columns, one per channel. I also created a custom format, (##0);_(##0);_(##0) , which hopefully would work as well.
rekkandevar As I said, there are no workbook functions or out of the box ways to use numbers in cells to fill a cell with RGB colors. This would require VBA. Are you open to that?