Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

If then else

Status
Not open for further replies.

Zeibaq

Technical User
Feb 10, 2004
1
US
I need to create an "IF, THEN, ELSE" statement with an "and" in the middle. How do I present the data fields in the formula. I keep receiving errors.
 
Since thread was started on 13 Feb I am assuming you may have already received and answer. In any case:

The IF THEN Statement
A=2
B=3
C=4
D=3
=if(a=2,1,0) equals 1
=if(and(a=b,c=d),1,0) equals 0, because both need to be true for “and”
or
=if(and(a>=b,c<=d),1,0) equals 0
or
=if(and(a<b,b<c,c>d),1,0) equals 1
or
if(or(a>b,c>d),1,0) equals 1, because only 1 needs to be true for “or”

Hope it helps.


Regards
Peter Buitenhek
Profit Developer.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top