I tried using steps identified here but realized that it refers to cells that have any formula in them. I would like to format based on one particular formula.
Is it possible to use conditional formatting to refer to a cell that only has a particular equation, for example an "IF" statement in the cell?
You don't mention what the formula is but do mention an IF statement so suggest (though clearly not Conditional Formatting in the conventional sense), HOME, Editing - Find & Select, Find what:
=*IF(*
Find All, Ctrl+A, and formatting of your choice.
Related
I've done some searching and I can't find anything that seems to match up with what I'm trying to do precisely. I'm familiar with Excel, formatting, and formulas, but by no means a master.
I have three sheets - Summary which is where the count value should be done, Tracker which is where the range to count is, and OrigTrackerData which has data used in the conditional formatting formula.
What I'm trying to do is count the number of cells within a certain table column that have a certain conditional formatting rule applied (rule below).
Here is the conditional formatting rule:
=A1<>VLOOKUP($A1,OrigTrackerData!$A:$L,COLUMN(),FALSE)
The intent of the rule, which is applied over the entirety of Table710 which exists in Tracker, is to determine which cells have changed relative to OrigTrackerData, regardless of row order of the two sheets - column A of both sheets have an "index" of sorts.
I've gotten as far as something like =COUNTIF(Table710[Notes], ???) but I can't determine how to convert the conditional formatting formula to a COUNTIF condition.
I am open to accomplishing this via VBA as well - I originally attempted to do so using color functions found here: http://www.cpearson.com/excel/colors.aspx but those functions apparently don't work on colors applied by conditional formatting.
Edit: BYate's comment neatly obviated the need for this. I am curious if something like this is possible though, but now just out of idle curiosity.
I have a rather quick hopefully not too complicated question for you guys. I'm trying to use conditional formatting where I want a cell to turn red if the following statements are False or If the conditions are not met.
I'm using the Formula for Conditional formatting where you have to input it manually. The real problem I'm having is using a nested AND and OR.
Here's the formula I have for conditional formatting (one thing to note that, maybe I could be wrong, but my 2013 Excel is treating OR as an AND and vice versa. I've tested it many times and this is the case, so the formula you see below treats OR and AND as I mentioned. In short, pretend that AND is OR and OR is AND. But if it confuses you, just go with the correct convention:
=AND(OR(SUM(A1:A5)=0,SUM(B2:B5)=0),OR(SUM(C1:C5)=0,SUM(D1:D5)=0),SUM(E1:E5)=0)
So basically, say I have cell 'A7'. I want 'A7' to be red until there's a number in
Both A1:A5 and B2:B5 or:
E1:E5 or;
Both C1:C5 and D1:D5 -----> here's where it doesn't work.
Points 1 and 2 above work as desired, but when I add the second 'OR' it doesn't work. Remember, for some reason my Excel COnditional Formatting treats OR like and AND and vice versa so when I say:
OR(SUM(A1:A5)=0,SUM(B1:B5)=0)
It treats it like an AND where both conditions must be true, therefore, I've been following this convention.
So basically how do I have more that one OR statements within AND as shown above.
I hope I made the question clear. Appreciate your guys help!! If you can also tell me a general rule on how nested And OR works, that would be helpful.
Thank you!
Select A7, fill it with red colour (standard fill), clear any existing CF from it and HOME > Styles - Conditional Formatting, New Rule..., Use a formula to determine which cells to format and Format values where this formula is true::
=OR(COUNT(E1:E5),AND(COUNT(A1:A5),COUNT(B2:B5)),AND(COUNT(C1:C5),COUNT(D1:D5)))
Format..., select No Colour fill, OK, OK.
Try this =IF(OR(AND((SUM(A1:A5)>0),(SUM(B2:B5)>0)),SUM(E1:E5)>0,AND((SUM(C1:C5)>0),(SUM(D2:D5)>0)))=FALSE,TRUE,FALSE)
I put this into a cell first and used the Evaluate Formula before pasting it into the Conditional rule.
Set the text to be red if this is true.
I have a question with regards to conditional formatting which I simply can't seem to solve.
The aim is to format the background color for the left-most cells that are blank up until a cell contains a value - and after this there should be no more formatting in this row. You can see an image of the result I'm hoping for beneath:
So far I've managed to create the conditional formatting of the blank rows, but sadly haven't managed to create the "single-cell" formatting (in yellow) conditional of the sum of all the first cells being = 0.
I've created a formula which actually succeeds in calculating the sum of the previous cells, but this formula includes INDIRECT() which it seems that conditional formatting doesn't allow. At least I'm getting an error starting with the follow (translating the error from Danish to English might not be intuitive):
You cannot use reference operators such as.....
The formula I'm trying is the following:
=AND(SUM(A2:INDIRECT(IF(COLUMN(A2)>=27;CHAR((64-26)+COLUMN(A2))&CHAR((64-26)+COLUMN(A2))&ROW(A2);CHAR((64)+COLUMN(A2))&ROW(A2))))>0;$K2>0)
Where $K2 is the sum of the row.
Is there a way to SUM a range of cells by doing something similar to this:
=SUM(B2:CHAR((64)+COLUMN())&ROW();"")) to dynamically SUM the range from B2 to the current cell? The problem in this case is whether the part CHAR((64)+COLUMN())&ROW();"") can be converted into a legible cell such as B4 to make it work inside the =SUM() formula?
Sadly the =ADDRESS() formula cannot be used (as far as I know) as this will trigger the same error in conditional formatting as well.
For now I would like this to work with the regular Excel conditional formatting, but if anyone have a simple VBA this would also have interest - however, I would by far prefer the regular solution.
The question:
Is there a way to create a formula that doesn't trigger this error - maybe by refrasing the formula or doing something completely else?
It seems to me that this could be handled with a much simpler CFR formula like,
=and(not(sum($a2:a2)), $k2)
Am I missing something?
I'm trying to color a cell red when the contents matches (at least) one of two other cells.
I've been trying this:
=AND(COUNTIF(CB17:CE17;CB55)=1,COUNTIF(CB18:CE18;CB55)=1)
and this:
=AND(COUNTIF(CB17:CE17;CB55)=1,COUNTIF(CB18:CE18;CB55)=1) = TRUE
but Excel doesn't recognize this as a formula ("There's a problem with this formula. Not trying to type a formula? ...")!
I can't get any conditional formatting formula to work with the AND operator it seems (and my Excel is the English version).
Any advice?
Edit:
some screenshots to clarify:
Error I get when using AND or the '+' operator in the formula:
Current contents of the criteria cells:
AND will be true of the expression inside results to true.
First of, you do not need to evaluate to 1 for AND to work. Secondly, you used ; and , instead of ;. You mentioned changing them to ; solved it.
So =AND( COUNTIF(...), COUNTIF(...) ) would already be enough.
Your formula would be =AND(COUNTIF(CB17:CE17;CB55);COUNTIF(CB18:CE18;CB55))
Now that being said, you want it to work for either of the values being true, that means you need an OR operator, not AND. The syntax is basically the same, just replace AND with OR. Your formula would be =OR(COUNTIF(CB17:CE17;CB55);COUNTIF(CB18:CE18;CB55))
Now since your ranges are CB17:CE17 and CB18:CE18 and they both evaluate to CB55, you could of course simply use =COUNTIF(CB17:CE18;CB55) which would be a lot simpler. I have explained the AND so you can learn from it, in case you really need to use more ranges and/or evaluate against different cells.
I am trying to write a conditional formatting formula for the rule "if the first cell of this row is NOT empty AND the current cell IS empty".
Basically I am trying to bring attention when a user has forgotten to enter a value in a cell.
The formula I came up with was:
="NOT(isblank($A1)) AND isblank(A1)"
Please provide an explanation why my formula is wrong, not just the correct formula =)
The logical "AND" is not an operator in Excel, it is just another function. Excel doesn't know how to evaluate =FUNCA() AND FUNCB(). Instead, wrap the two functions inside the AND function:
=AND(NOT(ISBLANK($A8)), ISBLANK(M8))