I am trying to apply a new conditional formatting rule and it is not working

Derquila

New Member
Joined
Oct 1, 2022
Messages
13
Office Version
  1. 2016
Platform
  1. Windows
Hello and let me apologize up front for this question.

I am trying to apply a new conditional formatting rule and it is not working

The rule is simple but it seeems to be formatting randomly. There are no other rules in the workbook. Column C is =B1>A1 etc.
Format where true =$B1>$A1
Apply to =$B$1:$B$19

1707088174838.png
 

Excel Facts

Formula for Yesterday
Name Manager, New Name. Yesterday =TODAY()-1. OK. Then, use =YESTERDAY in any cell. Tomorrow could be =TODAY()+1.
We cannot see your row numbers but it looks like you might have had the wrong cells selected when you applied the CF formula or else the CF formula is incorrect for the cells selected.

Can you give us the sample data with XL2BB?
 
Upvote 0
Hi. Column C is not part of the conditional formatting. It was included to illustrate the difference between a statement [Column C =B1>A1] which is working correctly and how the conditional formatting is handling the same statement incorrectly. I do not have access to the file at the moment but will return tomorrow or soon after. Thank you.
 
Upvote 0
Given some of the column C results in post 1, I am assuming that column B contains formulas so the cells that appear blank are not actually empty but contain a formula result of ""
If that is so, then I don't see how the formula in column C gives any different result to Conditional Formatting with the same formula .. unless, as I said before
you might have had the wrong cells selected when you applied the CF formula or else the CF formula is incorrect for the cells selected.
I am also swayed about wrong selection and/or wrong CF formula because you mentioned in post 1 about applying this CF to B1:B19 but your image only shows 18 rows.

Here is my sheet with column C formula the same as he formula in the CF

24 02 05.xlsm
ABC
1202401202402TRUE
2202401202401FALSE
3202401202402TRUE
4202401202401FALSE
5FALSE
6202402TRUE
7202402TRUE
8202402202402FALSE
9202402202402FALSE
10202402202402FALSE
11FALSE
122024030FALSE
132024030FALSE
142024030FALSE
15202403202403FALSE
16202403202404TRUE
17202403202404TRUE
18202403202403FALSE
CF
Cell Formulas
RangeFormula
C1:C18C1=$B1>$A1
Cells with Conditional Formatting
CellConditionCell FormatStop If True
B1:B18Expression=$B1>$A1textNO
 
Upvote 0
Unfortunately my IT it appears will not allow XL2BB to run (may need to restart). Here is an image of what I am seeing. Thank you.

Screenshot 2024-02-08 111221.png
 
Upvote 0
As Peter mentioned already, it looks like your selected range does not match up with the CF formula. You have selected A1 as the top of your range, but your CF formula starts at B2... so your highlights are not going to be accurate. Either keep the same selected range and change the formula to =$B1>$$A1, or change your selected range to start at A2 and keep the same CF formula.
 
Upvote 0
Here is an image of what I am seeing.
That confirms what I was getting at before. In that image, cell A1 is the active cell but the formula refers to row 2 cells.
it looks like you might have had the wrong cells selected when you applied the CF formula or else the CF formula is incorrect for the cells selected.

With both columns selected and A1 as the active cell, go back in to that conditional formatting dialog, click on the rule then Edit Rule and change the formula to =$B1>$A1
 
Last edited:
Upvote 0
Thank you, understand the issue. I did not realize we must set the application range to the location of condition statement.
 
Upvote 0
You just need to write your CF formula as it applies to the very first cell in the range you are applying it to, and then Excel will adjust the formula for all the other cells (depending on how you have set the range references, to be absolute, relative, or a mixture).

Since you have selected to apply it to all of columns A and B, your first cell in that range is cell A1.
If you don't want the Conditional Formatting to apply to row one, then don't select the entire column as the range to apply it to.
Start in cell A2 and go down as far as you want/need in column B.
 
Upvote 0

Forum statistics

Threads
1,215,068
Messages
6,122,950
Members
449,095
Latest member
nmaske

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top