Hi jdifrancesco1 -
Here are two methods:
Method 1 (The User Interface)
a. Select Cell A5 and choose |Format|Conditional Formatting...
b. Change Condition1 from "Cell Value Is" to "Formula Is"
c. In the reference box to the right of Condition1, enter the formula
"=A5>3" (without quotes).
d. Finally, press the [Format...] button and choose your fill color from the
pallete on the 'Patterns' tab.
Method 2 (VBA)
Place the following code in the module of the worksheet of interest:
Private Sub Worksheet_Change(ByVal Target As Range)
If Range("A8") > 3 Then Range("A8").Interior.ColorIndex = 5
End Sub
To find out which colors are available in the pallette, copy the following
utililty to a standard VB module and run it from a blank worksheet. The row
number of each color is its colorindex (to use in the procedure above):
Sub jdi_Pallette()
For i = 1 To 56
Cells(i, 1).Interior.ColorIndex = i
Next i
End Sub
--
Jay
"(E-Mail Removed)" wrote:
> Is there a formula I can use to change the fill color of a cell?
> like: IF A5>3 , color = 5
>
>
|