• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Formula for multiple conditions

Hii ,


See if this ok ?
cell E4;

=IF(AND(B4<>0,C4<>0),F4+G4+H4+I4+L4+M4,IF(AND(B4<>0,C4=0),F4+G4+H4+I4+J4+K4+L4+M4,IF(AND(B4=0,C4<>0),F4+L4+M4,IF(AND(B4=0,C4=0),F4+J4+K4+M4))))

Regards
Rahul shewale
 
Dear Narayank,

I have checked the file. You have tested two conditions at beginning.

Then you tested only one condition.

Each item to be checked for both the conditions always.

Regards,
Deb
 
Hii ,


See if this ok ?
cell E4;

=IF(AND(B4<>0,C4<>0),F4+G4+H4+I4+L4+M4,IF(AND(B4<>0,C4=0),F4+G4+H4+I4+J4+K4+L4+M4,IF(AND(B4=0,C4<>0),F4+L4+M4,IF(AND(B4=0,C4=0),F4+J4+K4+M4))))

Regards
Rahul shewale
Hi ,

The AND tests in the second , third and fourth IF statements are redundant.

Narayan
 
.........
=IF(AND(B4<>0,C4<>0),F4+G4+H4+I4+L4+M4,IF(AND(B4<>0,C4=0),F4+G4+H4+I4+J4+K4+L4+M4,IF(AND(B4=0,C4<>0),F4+L4+M4,IF(AND(B4=0,C4=0),F4+J4+K4+M4))))
Regards
Rahul shewale
Hi Rahul shewale,

In the 2nd IF statement, "...+L4..." (highlighted in red color) is not required.

=IF(AND(B4<>0,C4<>0),F4+G4+H4+I4+L4+M4,IF(AND(B4<>0,C4=0),F4+G4+H4+I4+J4+K4+L4+M4,IF(AND(B4=0,C4<>0),F4+L4+M4,IF(AND(B4=0,C4=0),F4+J4+K4+M4))))

Regards
Bosco
 
Last edited:
Back
Top