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 derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

If statement help 1

Status
Not open for further replies.

Legends77

Technical User
Jan 18, 2009
57
US
What I am needing to do is a "if and" statement. I.E.
=IF(D11="Waste Disposal",E11-M11-O11,IF(D11="Property Taxes"& A11="1105006",ROUND(+E11*G11,20)+20000,IF(D11="Depreciation" & A11="1105006",ROUND(+E11*G11,20)+54000,ROUND(+E11*G11,20))))

Without the "&" portion of each if it works great but really need the "and". Tried spelling out "and" but get formula errors.

Any help is greatly appreciated.
 
It's AND(case1,case1) syntax.

Cheers, Glenn.

Beauty is in the eye of the beerholder.
 
Thanks! This was driving me nuts and will help me out in other files as well!
 
You might also want to look at the OR() function to fill that need when you bump into it.


-
Richard Ray
Jackson Hole Mountain Resort
 
Is there any way to use this AND() or the OR() with a SUMIF statement?
current formula:
=SUMIF(PROD!$P:$P,$A22,PROD!$F:$F)/1000

What I need to do is
sumif(PROD!$P:$P,$A22 and PROD!$C:C$,$A$36,PROD!$F:$F)/1000
Tried:
sumif(And(PROD!$P:$P,$A22,PROD!$C:C$,$A$36),PROD!$F:$F)/1000
but receive an error and think it is because of all the ",'s" in the "AND" portion that is messing up the logic.

Therefore, I tried:
sumif(And(PROD!$P:$P=$A22,PROD!$C:C$=$A$36),PROD!$F:$F)/1000
but also receive an error and think this is beause I am not following a true "SUMIF"

Any suggestions?
 
What version of Excel are you using?

Cheers, Glenn.

Beauty is in the eye of the beerholder.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top