orerockon
asked on
Change a cell's color based on another cell's color
I created a macro, "GetFontColor":
Function GetFontColor(Rng As Range) As Long
GetFontColor = Rng.Font.Color
End Function
Now I need to format the font color for a range of cells using the results of the function. So for example, if I format a cell's text to red, the formula returns "255". So in another cell, I would like to also change the color to the referenced cell's color (or any other color for that matter). I think I can do this with conditional formatting using a formula but it doesn't seem to work: Format using a formula... type "GetFontColor($A$1)=255" then format the font color red. Nothing happens.
Function GetFontColor(Rng As Range) As Long
GetFontColor = Rng.Font.Color
End Function
Now I need to format the font color for a range of cells using the results of the function. So for example, if I format a cell's text to red, the formula returns "255". So in another cell, I would like to also change the color to the referenced cell's color (or any other color for that matter). I think I can do this with conditional formatting using a formula but it doesn't seem to work: Format using a formula... type "GetFontColor($A$1)=255" then format the font color red. Nothing happens.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER