View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
vezerid vezerid is offline
external usenet poster
 
Posts: 751
Default "IF" Statement Problem

Putting them together --
=IF('Requestor Information'!E28<"",'Requestor
Information'!E28),IF(AND(C5<0,'Requestor
Information'!G35="Yes"),SUM('Requestor
Information'!E28+7+3)),IF(AND(C5<0,(OR('Requestor
Information'!G35="No",'Requestor Information'!G35=""))),SUM('Requestor
Information'!E28+7+1))


lajohn,
You are closing the parentheses too quickly. For a nested if w/ 3
outcomes you have the following:

=IF(cond1, outcome1, IF(cond2, outcome2, outcome3))

What you are doing:

=IF(cond1, outcome1),IF(cond2,outcome2),IF(...

As you see your are finishing your IF too quickly. Correcting your
formula:

=IF('Requestor Information'!E28<"",'Requestor
Information'!E28,IF(AND(C5<0,'Requestor
Information'!G35="Yes"),SUM('Requestor
Information'!E28+7+3),IF(AND(C5<0,OR('Requestor
Information'!G35="No",'Requestor Information'!G35="")),SUM('Requestor
Information'!E28+7+1))))

HTH
Kostis Vezerides