ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   if statement when cell is blank (https://www.excelbanter.com/excel-worksheet-functions/198236-if-statement-when-cell-blank.html)

davisk

if statement when cell is blank
 
If G3 is a date and F3 is equal to
IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE"))
How do I return "n/a" to F3 if G3 is left blank?

ward376

if statement when cell is blank
 
=IF(G3="","n/a",IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE")))

cLIFF eDWARDS

Gary''s Student

if statement when cell is blank
 
=if(G3="","n/a",IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE")))
--
Gary''s Student - gsnu200798

Rick Rothstein \(MVP - VB\)[_1062_]

if statement when cell is blank
 
I notice you do not have anything in the FALSE condition of your 2nd IF
statement to handle dates in G3 exactly equal to TODAY()-2 and TODAY()-3...
the formula reports FALSE for those two dates. Perhaps you meant = and <=
instead of and < in both of your IF tests?

Anyway, to do what you want, put this...

IF(G3="","N/A",

in front of your current formula (after the = sign, of course) and put a
closing parenthesis after at the end. Using your posted formula, the above
comments notwithstanding, this is what the formula becomes after doing
that...

=IF(G3="","N/A",IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE")))

Rick


"davisk" wrote in message
...
If G3 is a date and F3 is equal to
IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE"))
How do I return "n/a" to F3 if G3 is left blank?



davisk

if statement when cell is blank
 
perfect...thanks you both~k:-)

"Gary''s Student" wrote:

=if(G3="","n/a",IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE")))
--
Gary''s Student - gsnu200798


davisk

if statement when cell is blank
 
Can I also add "Closed" to same formula if another cell other than G3 is
populated w/"yes"?



"Rick Rothstein (MVP - VB)" wrote:

I notice you do not have anything in the FALSE condition of your 2nd IF
statement to handle dates in G3 exactly equal to TODAY()-2 and TODAY()-3...
the formula reports FALSE for those two dates. Perhaps you meant = and <=
instead of and < in both of your IF tests?

Anyway, to do what you want, put this...

IF(G3="","N/A",

in front of your current formula (after the = sign, of course) and put a
closing parenthesis after at the end. Using your posted formula, the above
comments notwithstanding, this is what the formula becomes after doing
that...

=IF(G3="","N/A",IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE")))

Rick


"davisk" wrote in message
...
If G3 is a date and F3 is equal to
IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE"))
How do I return "n/a" to F3 if G3 is left blank?




davisk

if statement when cell is blank
 
Please disregard new request; I figured it out:-)

"davisk" wrote:

Can I also add "Closed" to same formula if another cell other than G3 is
populated w/"yes"?



"Rick Rothstein (MVP - VB)" wrote:

I notice you do not have anything in the FALSE condition of your 2nd IF
statement to handle dates in G3 exactly equal to TODAY()-2 and TODAY()-3...
the formula reports FALSE for those two dates. Perhaps you meant = and <=
instead of and < in both of your IF tests?

Anyway, to do what you want, put this...

IF(G3="","N/A",

in front of your current formula (after the = sign, of course) and put a
closing parenthesis after at the end. Using your posted formula, the above
comments notwithstanding, this is what the formula becomes after doing
that...

=IF(G3="","N/A",IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE")))

Rick


"davisk" wrote in message
...
If G3 is a date and F3 is equal to
IF(G3TODAY()-2,"OPEN",IF(G3<TODAY()-3,"PAST DUE"))
How do I return "n/a" to F3 if G3 is left blank?





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

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