Home |
Search |
Today's Posts |
#1
|
|||
|
|||
If and Or statement
I am having trouble creating an If and Or statement:
My spreadsheet looks like this: A1 100 A2 200 A3 300 A4 600 A4 is just a sum of the 3 cells above it. I want to say if any of the cells above the total line is negative then dont add that particular cell. I can do it if one cell is negative but what about 2? |
#2
|
|||
|
|||
=SUM(IF(A1:A40,A1:A4)
which is an array formula, so commit with Ctrl-Shift-Enter. -- HTH Bob Phillips "Matt" wrote in message ... I am having trouble creating an If and Or statement: My spreadsheet looks like this: A1 100 A2 200 A3 300 A4 600 A4 is just a sum of the 3 cells above it. I want to say if any of the cells above the total line is negative then dont add that particular cell. I can do it if one cell is negative but what about 2? |
#3
|
|||
|
|||
On Wed, 29 Jun 2005 07:31:11 -0700, "Matt"
wrote: I am having trouble creating an If and Or statement: My spreadsheet looks like this: A1 100 A2 200 A3 300 A4 600 A4 is just a sum of the 3 cells above it. I want to say if any of the cells above the total line is negative then dont add that particular cell. I can do it if one cell is negative but what about 2? =SUMIF(A1:A3,"0") --ron |
#4
|
|||
|
|||
How about plain, old:
=SUMIF(A1:A4,"0") ??? -- HTH, RD ============================================== Please keep all correspondence within the Group, so all may benefit! ============================================== "Bob Phillips" wrote in message ... =SUM(IF(A1:A40,A1:A4) which is an array formula, so commit with Ctrl-Shift-Enter. -- HTH Bob Phillips "Matt" wrote in message ... I am having trouble creating an If and Or statement: My spreadsheet looks like this: A1 100 A2 200 A3 300 A4 600 A4 is just a sum of the 3 cells above it. I want to say if any of the cells above the total line is negative then dont add that particular cell. I can do it if one cell is negative but what about 2? |
#5
|
|||
|
|||
Oh don't be so boring :-)
-- HTH Bob Phillips "RagDyeR" wrote in message ... How about plain, old: =SUMIF(A1:A4,"0") ??? -- HTH, RD ============================================== Please keep all correspondence within the Group, so all may benefit! ============================================== "Bob Phillips" wrote in message ... =SUM(IF(A1:A40,A1:A4) which is an array formula, so commit with Ctrl-Shift-Enter. -- HTH Bob Phillips "Matt" wrote in message ... I am having trouble creating an If and Or statement: My spreadsheet looks like this: A1 100 A2 200 A3 300 A4 600 A4 is just a sum of the 3 cells above it. I want to say if any of the cells above the total line is negative then dont add that particular cell. I can do it if one cell is negative but what about 2? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Do I need a sumif or sum of a vlookup formula? | Excel Worksheet Functions | |||
IF Statement nightmare | Excel Discussion (Misc queries) | |||
IF Statement | New Users to Excel | |||
How do I fix a circular reference in a financial statement? | Excel Discussion (Misc queries) | |||
7+ nested if statement? | Excel Worksheet Functions |