Thanks for looking at this Earl, you are right, this is what i'm trying to
do. It sure would be nice if it was an option on the conditional formatting
to not stop on first true, but continue down the list applying what
satisfies the condition.
Now there seems to be two other bugs that I've found.
1. Using indirect addressing within the AND statement for conditional
formatting doesn't work.
example:
if the conditional forrmating is:
formula is: =(INDIRECT(ADDRESS(ROW(),COLUMN()-1))<>"")
this evaluates to true but if the conditional formatting is:
formula is: =AND((INDIRECT(ADDRESS(ROW(),COLUMN()-1))<>""), TRUE )
this doesn't evaluate to true.
Of course, i'm using something more than TRUE, but this reproducer fails to
work properly.
I got around this problem by using r1c1 style references and the formula:
formula is: =AND(rc[-1]<>"", TRUE)
evaluates to true correctly.
Using this caused me to find the next bug:
2. Inserting a row modifies unpredictably modifies the conditional
formatting.
I applied conditional formatting over three columns that uses r1c1 style
references as shown above. When I insert a row, the first column's
conditional formatting isn't global to the column any more because the
references around which i've inserted have been linked to the old cells,
causing them to be unique. What's weird is the other two columns are fine.
Here are the column conditional formatting rules, all have 3 formulas with
the first formatting the cell according to condition 2 and 3.
Column 1:
=AND(RC[-1]<>"", R[1]C<>RC)
=R[1]C<>RC
=RC<>""
Column 2:
=AND(R[1]C[-1]<>RC[-1],RC<>"")
=R[1]C[-1]<>RC[-1]
=(RC<>"")
Column 3:
=AND(RC[-1]<>"", R[1]C[-2]<>RC[-2])
= R[1]C[-2]<>RC[-2]
=RC[-1]<>""
It seems like the deeper I dig, the more holes I find.
Thanks,
Shawn
Earl Kiosterud said:
Shawn,
Conditional formatting will apply formats for only one of the three
conditions. It has no choice if you have formats that are exclusive (like
red for one condition, green for another, etc.). But I suspect you've set
up formats that are not exclusive (like red for one condition, bold for
another) where you'd like to have them both applied when both their
conditions are TRUE. But since it applies format(s) for only one of the
three conditions, it stops after finding the first of the three formulas
that resolves to TRUE (thus prioritizing them for the case where more than
one condition is satisfied -- it uses the first condition that is TRUE).
Remember that formats from any or all of the three tabs (font, border, and
patterns) can be applied for each condition.
If you want to apply multiple formats, each with their own condition, I
suspect you'll have to do that with a macro.
Or this the condition where I've TOTALLY missed the point?
Earl Kiosterud
mvpearl omitthisword at verizon period net