Can can't get my first or logical pass to ignore a blank cell

Viewed 20

I am trying to ignore a logical argument in an IF(OR()) if a blank exists.

=IF(OR(AND(C4>0,TODAY()-F4>250),AND(C4=0,TODAY()-D4>60)),"Sell Now", "Check back in 30")

At TODAY()-F4>250 I get a Value error if there is no data in Cell F4. I have tried variants of modifying with ISNUMBER or ISBLANK but it throws off my Logical condition and gives me false negatives when it should return TRUE.

Can I modify it somehow where if a blank exists, to proceed to the second condition in the OR argument at AND(C4=0,TODAY()-D4>60)) ? Thank you

I'm really just trying to say if this condition is true or this condition is true - sell now, otherwise check back. If I have a blank on that first argument it throws it off.

1 Answers

Use IFERROR:

If you still want the C4>0 check to happen:

=IF(OR(AND(C4>0,IFERROR(TODAY()-F4>250,TRUE)),AND(C4=0,TODAY()-D4>60)),"Sell Now", "Check back in 30")

If you want to skip the C4>0 check as well:

=IF(OR(IFERROR(AND(C4>0,TODAY()-F4>250),FALSE),AND(C4=0,TODAY()-D4>60)),"Sell Now", "Check back in 30")

It's not exactly apparent whether you want the second argument of IFERROR to be TRUE or FALSE; adjust according to whether you want the first condition to pass or not.

Related