Conditional Formating on Several Cells

D

Damon

So, I've added conditional formating to A2 that logically looks like this:
=if C2=0 then fill is red and if C2=1 then fill is green

I need this formating on the next 80 cells in column A and I need the check
to be on C3,4,5,6,... and so on. How do i copy the conditional formating
like that?
 
S

Sheeloo

Paint the formatting in A2 down the range...

It does copy ALL formatting...

You can also select the range and then enter the formula which applies to
the first cell/row in the range. Excel will adjust the cell for other
cells/rows in the selection.
 
D

Damon

Thanks...
I tried that before and it didn't work, but this time i removed the default
$ from the formula applied to A2 and then the paint worked.
 
D

David Biddulph

If you copy that conditional formatting down, whether by copying the cell,
or by Copy/ Edit/ Paste Special/ Format, or by the Format Painter, then you
will get the result you asked for. If the CF formula is still referring to
C2 as you copy it down, make sure that you didn't mistakenly refer to C$2
rather than C2.
 
S

Sheeloo

Glad you noticed that... I forgot to warn you about that... as David
mentioned below in his post
 
M

Mike

Ok, I have the exact same problem, but I can't get it to work. I actually
converted a 2003 file with allot of VBA in it, and all the conditional
formats are messed up because when it copies (special..formats only) from one
cell to multiple cells, the cell I am checking does not change with the row.
Example: I have a conditional format that goes =or(a4>$a$170, a4<$a$171) with
a condition that it has a red background. This conditional format would be
initially in cell a4. Then I copy cell a4, highlight a5 through a100 and
"paste special" formats only, every cell has the exact same condition. I
need the a4 to change with the row as it is copied but it won't do it. What
am I doing wrong?????
 
S

Sheeloo

I think it is a matter of understanding...

Excel 2007 shows the formula in the first cell and also shows the range it
is applied to in a separate box...

The condition you have is correct...

Just to make sure...
Delete all conditional formattin
Select the first cell, apply the format and in the applies to box enter the
range you want it applied to...

Anything without a $ changes and anything with a $ does not change.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top