Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I'm looking to total a range of cells ONLY if they have a value of 0 or more
entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#2
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Hi
Try something like this: =SUMPRODUCT((D7:G70)*(D7:G7)) AndyB "Powlaz" wrote in message ... I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#3
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Kevin, Andy, thanks for the quick responses. Both of your formulas worked
(as far as I can tell). I'm interested in understanding how they work if you could offer a quick explanation. Moreso, I need a little more help. Both the formulas returned a 0 when summing a range of blank cells. Here's the issue, this spreadsheet is pre - formatted for a year's worth of data. I'd like for the cells in an unused month to remain blank until the data is entered (and subsequently calculated). There is currently no user added data in cells b6:b12. But cell b13 that calculates the total of b6:b12 shows 0. I'd like it to be blank until data is entered into b6:b12. How can I concisely do that? I thought about using IF and OR functions combined so that each cell is checked for a value greater than "" before it will calculate the total of the cells but it's very long and I think inefficient. Got anything else? Thanks PO "AndyB" wrote: Hi Try something like this: =SUMPRODUCT((D7:G70)*(D7:G7)) AndyB "Powlaz" wrote in message ... I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#4
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
=IF(COUNTIF(SumRange,"=0")=ROWS(SumRange),SUM(Sum Range),"")
My sumrange was a1:a10 so rows(sumrange) returns 10. The countif will count the number of occurences where the cells in sumrange = 0. If all of the cells meet the criteria, this will equal 10. Therefore the true portion of the IF statement will be returned which is SUM(Sumrange). Otherwise "" (nothing) will be returned. This per your latest request to have "" shown rather than ). HTH -- Kevin Vaughn "Powlaz" wrote: Kevin, Andy, thanks for the quick responses. Both of your formulas worked (as far as I can tell). I'm interested in understanding how they work if you could offer a quick explanation. Moreso, I need a little more help. Both the formulas returned a 0 when summing a range of blank cells. Here's the issue, this spreadsheet is pre - formatted for a year's worth of data. I'd like for the cells in an unused month to remain blank until the data is entered (and subsequently calculated). There is currently no user added data in cells b6:b12. But cell b13 that calculates the total of b6:b12 shows 0. I'd like it to be blank until data is entered into b6:b12. How can I concisely do that? I thought about using IF and OR functions combined so that each cell is checked for a value greater than "" before it will calculate the total of the cells but it's very long and I think inefficient. Got anything else? Thanks PO "AndyB" wrote: Hi Try something like this: =SUMPRODUCT((D7:G70)*(D7:G7)) AndyB "Powlaz" wrote in message ... I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#5
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Kevin,
Great - I get it. Thank you for the explanation. Works perfectly. I didn't use a label (SumRange). I like to see the range in the equation. But I've run into a little problem doing it that way. One part of the spreadsheet requires me to use this statement for cells that are not in sequence. The COUNTIF function will not allow more than 3 cell references, where I need 8 (b6,d6,f6,h6,j6 etc.) Is there a way to make COUNTIF accept more than 3 cell references for cells that are not in sequence? PO "Kevin Vaughn" wrote: =IF(COUNTIF(SumRange,"=0")=ROWS(SumRange),SUM(Sum Range),"") My sumrange was a1:a10 so rows(sumrange) returns 10. The countif will count the number of occurences where the cells in sumrange = 0. If all of the cells meet the criteria, this will equal 10. Therefore the true portion of the IF statement will be returned which is SUM(Sumrange). Otherwise "" (nothing) will be returned. This per your latest request to have "" shown rather than ). HTH -- Kevin Vaughn "Powlaz" wrote: Kevin, Andy, thanks for the quick responses. Both of your formulas worked (as far as I can tell). I'm interested in understanding how they work if you could offer a quick explanation. Moreso, I need a little more help. Both the formulas returned a 0 when summing a range of blank cells. Here's the issue, this spreadsheet is pre - formatted for a year's worth of data. I'd like for the cells in an unused month to remain blank until the data is entered (and subsequently calculated). There is currently no user added data in cells b6:b12. But cell b13 that calculates the total of b6:b12 shows 0. I'd like it to be blank until data is entered into b6:b12. How can I concisely do that? I thought about using IF and OR functions combined so that each cell is checked for a value greater than "" before it will calculate the total of the cells but it's very long and I think inefficient. Got anything else? Thanks PO "AndyB" wrote: Hi Try something like this: =SUMPRODUCT((D7:G70)*(D7:G7)) AndyB "Powlaz" wrote in message ... I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#6
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Kevin,
I looked at everything again and I'm afraid I'm not where I need to be. Bear with me. I'm not sure if I worded my question well enough. I have a table in which each column represents a month. The first line of each column is a total of the 7 lines below it. The last column is an average of each monthly total. 1st. I'd like to keep a running average of the totals in each month. If there is no value entered in the 'Total' cell for a month I don't want "0" to show up. Using the statement you gave me before all of my 0's went away when the 'Total' cells were blank. When I entered a total into January (b6) the average calcualted in AA6. But when I entered a total into February (d6) the average in AA6 disappeared. What's the fix? 2nd. I'd like to keep a running total of jobs for the month. In January these would be cells a7:a13. If I just use SUM there is a 0 in a14 until data is entered into one of the cells a7:a13. I'd like a14 to stay blank and calculate a total as each cell is populated: a7 = 5 a14= 5 a7=5 a8=5 a14=10 ---and so on. What am I missing? PO "Kevin Vaughn" wrote: =IF(COUNTIF(SumRange,"=0")=ROWS(SumRange),SUM(Sum Range),"") My sumrange was a1:a10 so rows(sumrange) returns 10. The countif will count the number of occurences where the cells in sumrange = 0. If all of the cells meet the criteria, this will equal 10. Therefore the true portion of the IF statement will be returned which is SUM(Sumrange). Otherwise "" (nothing) will be returned. This per your latest request to have "" shown rather than ). HTH -- Kevin Vaughn "Powlaz" wrote: Kevin, Andy, thanks for the quick responses. Both of your formulas worked (as far as I can tell). I'm interested in understanding how they work if you could offer a quick explanation. Moreso, I need a little more help. Both the formulas returned a 0 when summing a range of blank cells. Here's the issue, this spreadsheet is pre - formatted for a year's worth of data. I'd like for the cells in an unused month to remain blank until the data is entered (and subsequently calculated). There is currently no user added data in cells b6:b12. But cell b13 that calculates the total of b6:b12 shows 0. I'd like it to be blank until data is entered into b6:b12. How can I concisely do that? I thought about using IF and OR functions combined so that each cell is checked for a value greater than "" before it will calculate the total of the cells but it's very long and I think inefficient. Got anything else? Thanks PO "AndyB" wrote: Hi Try something like this: =SUMPRODUCT((D7:G70)*(D7:G7)) AndyB "Powlaz" wrote in message ... I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#7
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
I don't know why your average formula would go blank. What is the formula in
AA6? For your 2nd question, this formula should work: =IF(COUNT(A8:A13)0,SUM(A8:A13),"") -- Kevin Vaughn "Powlaz" wrote: Kevin, I looked at everything again and I'm afraid I'm not where I need to be. Bear with me. I'm not sure if I worded my question well enough. I have a table in which each column represents a month. The first line of each column is a total of the 7 lines below it. The last column is an average of each monthly total. 1st. I'd like to keep a running average of the totals in each month. If there is no value entered in the 'Total' cell for a month I don't want "0" to show up. Using the statement you gave me before all of my 0's went away when the 'Total' cells were blank. When I entered a total into January (b6) the average calcualted in AA6. But when I entered a total into February (d6) the average in AA6 disappeared. What's the fix? 2nd. I'd like to keep a running total of jobs for the month. In January these would be cells a7:a13. If I just use SUM there is a 0 in a14 until data is entered into one of the cells a7:a13. I'd like a14 to stay blank and calculate a total as each cell is populated: a7 = 5 a14= 5 a7=5 a8=5 a14=10 ---and so on. What am I missing? PO "Kevin Vaughn" wrote: =IF(COUNTIF(SumRange,"=0")=ROWS(SumRange),SUM(Sum Range),"") My sumrange was a1:a10 so rows(sumrange) returns 10. The countif will count the number of occurences where the cells in sumrange = 0. If all of the cells meet the criteria, this will equal 10. Therefore the true portion of the IF statement will be returned which is SUM(Sumrange). Otherwise "" (nothing) will be returned. This per your latest request to have "" shown rather than ). HTH -- Kevin Vaughn "Powlaz" wrote: Kevin, Andy, thanks for the quick responses. Both of your formulas worked (as far as I can tell). I'm interested in understanding how they work if you could offer a quick explanation. Moreso, I need a little more help. Both the formulas returned a 0 when summing a range of blank cells. Here's the issue, this spreadsheet is pre - formatted for a year's worth of data. I'd like for the cells in an unused month to remain blank until the data is entered (and subsequently calculated). There is currently no user added data in cells b6:b12. But cell b13 that calculates the total of b6:b12 shows 0. I'd like it to be blank until data is entered into b6:b12. How can I concisely do that? I thought about using IF and OR functions combined so that each cell is checked for a value greater than "" before it will calculate the total of the cells but it's very long and I think inefficient. Got anything else? Thanks PO "AndyB" wrote: Hi Try something like this: =SUMPRODUCT((D7:G70)*(D7:G7)) AndyB "Powlaz" wrote in message ... I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#8
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
This worked for me. First I named the range I wanted to sum SumRange
(clever, eh?) I then used this formula: =IF(COUNTIF(SumRange,"0")=ROWS(SumRange),SUM(SumR ange),0) "Powlaz" wrote: I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
#9
![]()
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
![]()
Slight change:
=IF(COUNTIF(SumRange,"=0")=ROWS(SumRange),SUM(Sum Range),0) "Kevin Vaughn" wrote: This worked for me. First I named the range I wanted to sum SumRange (clever, eh?) I then used this formula: =IF(COUNTIF(SumRange,"0")=ROWS(SumRange),SUM(SumR ange),0) "Powlaz" wrote: I'm looking to total a range of cells ONLY if they have a value of 0 or more entered in them. In plain english: Sumif A1 is =0 Sumif A2 is =0 Sumif A3 is =0 and so on. Where every cell in the range must have a value of 0 or more entered before the function will return a result. How do I do this? Thanks, PO |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How to use SUMIF to return sums between two values located in cells | Excel Worksheet Functions | |||
Checking Blank Cells | Excel Worksheet Functions | |||
pivot tables reports - altering display of (blank) cells | Excel Worksheet Functions | |||
Copy down - special to fill only the blank cells | Excel Discussion (Misc queries) | |||
Non Blank - Blank Cells???? | Excel Discussion (Misc queries) |