I want to compare a cell to its adjacent cell on the left. If the value of the selected cell is higher I'd like to colour it green, if it's the same I'd like to colour it orange and if it's below I'd like to colour it red. I can set up a macros that will do this if the cells I'm comparing are all in the same column, but I'd like one that would work anywhere on the page. Does anyone know how to do this?
sorry for misunderstanding. I do not mean that you should change the formula in the cell. But you introduce the formula in "conditional formatting".
select the cell B2
click format-conditional formatting
in this window
under condition 1 choose "the formula is"
on the right side write the formula
click format in the second line of this window
format window opens
in this window choose "pattern" the right end of the choices at the top
choose color (green)
you are back in conditional formatting window
click add (at the bottom left)
in condition2 give the second formula and follow other steps (including click ok)
you are again back to conditional formatting windowa
again click add and type the third formula
repeat steps(including ok)
you are back in the conditional formatting window
now click ok in this window
check whether the original formula in B2 changed. It won't be.
you can have three conditions in conditional formatting in excel versions 2003 and before.
in excel 2007 you can have more.
now select B2 and click edit-copy (or control+c) now select all other cells from column 2 to the right and click edit-pastespecial and then choose format. click ok
the conditional formatting in the cells are created by there should not be any change in the existing formulas. you can test it by selecting any cell and click foramt -conditional formatting.