ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   need help with conditional formatting 3 criteria (https://www.excelbanter.com/excel-worksheet-functions/118185-need-help-conditional-formatting-3-criteria.html)

[email protected]

need help with conditional formatting 3 criteria
 
I want odd columns to use a red font, and even columns to use a blue
font.
I have this working now using two conditional formatting criteria.

Now I want to add another criteria that formats any negative values in
an even column to have a yellow background, but I can't get it to work.

I tried something like =AND(MOD(COLUMN(),2)=0,A1<0) as the 3rd
criteria of the type FORMULA IS.

I thought this would work, but it doesn't. In fact, that above
criteria doesn't even work when used all by itself on another sheet.

Have I run into undocumented limitations of conditional formatting?

Thanks,

Brian Murphy
Austin, Texas


David Biddulph

need help with conditional formatting 3 criteria
 
That criterion works by itself, but if you've got the "even columns in blue
font" criterion earlier it will take that in preference.

If you put your more restrictive condition [the AND() criterion] first, with
the separate even column one later, it will put your negative evens on the
yellow background (but if you want the blue font you'll need to include that
in the first format). The remainder of the even column entries will be
given the blue font by the later condition.
--
David Biddulph

wrote in message
ups.com...
I want odd columns to use a red font, and even columns to use a blue
font.
I have this working now using two conditional formatting criteria.

Now I want to add another criteria that formats any negative values in
an even column to have a yellow background, but I can't get it to work.

I tried something like =AND(MOD(COLUMN(),2)=0,A1<0) as the 3rd
criteria of the type FORMULA IS.

I thought this would work, but it doesn't. In fact, that above
criteria doesn't even work when used all by itself on another sheet.

Have I run into undocumented limitations of conditional formatting?

Thanks,

Brian Murphy
Austin, Texas




[email protected]

need help with conditional formatting 3 criteria
 
Thank you, David.

I tried it that way, and it worked!

I thought I already tried that yesterday. Whatever I did then did not
work.

Anyway, now I've got what I wanted.

Cheers,

Brian



All times are GMT +1. The time now is 01:38 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com