Dear users,
I am new to this forum and hope to get some help on the following and possible future problems.
I have a problem nesting four "IF" statements into one function.
The several other threads on this problem helped me to no avail.
Here are my four statements:
The goal is to retrieve data from another sheet (hence the "INDIRECT" statements), depending on two variables.
The individual statements work perfectly, but combining them in any way gives me errors. I'm not sure if the problem is too many statements in my function.
I'm using Excel 2008 for Mac.
Thank you for your thoughts.
Johan
I am new to this forum and hope to get some help on the following and possible future problems.
I have a problem nesting four "IF" statements into one function.
The several other threads on this problem helped me to no avail.
Here are my four statements:
Code:
=IF(AND($H$5="any";$H$7<>"any");SUMPRODUCT((INDIRECT($I$3&"!I30:I40"))*(INDIRECT($I$3&"!D30:D40")=$I$7)))
=IF(AND($H$5<>"any";$H$7="any");SUMPRODUCT((INDIRECT($I$3&"!I30:I40"))*(INDIRECT($I$3&"!C30:C40")=$H$5)))
=IF(AND($H$5<>"any";$H$7<>"any");SUMPRODUCT((INDIRECT($I$3&"!I30:I40"))*(INDIRECT($I$3&"!C30:C40")=$H$5)*(INDIRECT($I$3&"!D30:D40")=$I$7)))
=IF(AND($H$5="any";$H$7="any");SUM(INDIRECT($I$3&"!I30:I40")))
The individual statements work perfectly, but combining them in any way gives me errors. I'm not sure if the problem is too many statements in my function.
I'm using Excel 2008 for Mac.
Thank you for your thoughts.
Johan