Not sure how to format this if statement

G

Guest

I'm having difficulty forming this statement and would be grateful for
assistance.

Cell D1 contains the formula
If cell A1 is empty then cell D1 remains empty
If cell A1 contains a date and cell B1 is empty then cell D1 returns
"Outstanding"
If cell A1 contains a date and cell B1 contains text then cell D1 remains
empty
If cell A1 contains a date and cell B1 is empty and cell C1 contains a date
then cell D1 returns "Cleared"

Thank you
 
G

Guest

I've kept this simple by assuming:
A1 & C1 can only be empty or contain a date and any entry into B1 will only
be a comment (text)

=if(A1 =
"","",if(and(A1<>"",b1="",c1=""),"Outstanding",if(and(A1<>"",B1<>"",C1=""),"",if(and(A1<>"",B1="",C1<>""),"Cleared","ERROR!"))))

I've added the error condition in case an operator should fail to erase B1
when adding a date to C1.

HTH

Giz
 
G

Guest

Thanks very much this is exactly what I needed.

Gizmo63 said:
I've kept this simple by assuming:
A1 & C1 can only be empty or contain a date and any entry into B1 will only
be a comment (text)

=if(A1 =
"","",if(and(A1<>"",b1="",c1=""),"Outstanding",if(and(A1<>"",B1<>"",C1=""),"",if(and(A1<>"",B1="",C1<>""),"Cleared","ERROR!"))))

I've added the error condition in case an operator should fail to erase B1
when adding a date to C1.

HTH

Giz
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top