Conditional Formatting

  • Thread starter Thread starter Sherry N.
  • Start date Start date
S

Sherry N.

Hello,
I have a worksheet where I need the cells in Column C to turn yellow if the
cell in Column B is less than a cell in Column G. I used this formula for the
conditional formatting in C2 =IF($B$2<$G$128,1,0) and it does work. However I
need the whole column to have the same conditional formatting when I paste
formats it just pastes the exact same formula. I want the next one to be
=If($B3<$G128,1,0). Is there a way I can paste formats that would use step
value or would I have to do the condtional formatting for each cell?
 
Highlight all the cells in column C that you want this to apply to, with C2
being the first cell in this range. Click on Format | Conditional
Formatting, select Formula Is in the first panel, and enter this formula in
the next panel:

=$B2<$G$128

Click on the Format button then select the Patterns tab to change the
background colour to yellow, then OK your way out.

Hope this helps.

Pete
 
Thanks so much works great. How can I add another condition that would make
the blank cells have no formatting? Thanks again.
 
Hightlight all the cells again and amend the formula like this:

=AND($C2<>"",$B2<$G$128)

Hope this helps.

Pete
 
PERFECT! Thanks again!
--
Sherry N.


Pete_UK said:
Hightlight all the cells again and amend the formula like this:

=AND($C2<>"",$B2<$G$128)

Hope this helps.

Pete
 
Back
Top