Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
SumIf Question
I have a spreadsheet that I need to do a calculation if the answer is yes or
"Y". I put the formula below in and it works correctly for the "N" formula. If the answer is "Y" the formula does not give me the sum of F1+G1 (actually "-" but I put the number in as a negative) but the total of F1 instead. =SUMIF(H1,"Y",F1:G1)+SUMIF(H1,"N",F1) |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
SumIf Question
=sumif()
is usually used to compare a range of values against another value. Then add the values in the other range. If you're really only checking H1, maybe just changing your formula would be easiest: =if(h1="y",sum(f1:g1),0) + if(h1="n",f1,0) Ronda wrote: I have a spreadsheet that I need to do a calculation if the answer is yes or "Y". I put the formula below in and it works correctly for the "N" formula. If the answer is "Y" the formula does not give me the sum of F1+G1 (actually "-" but I put the number in as a negative) but the total of F1 instead. =SUMIF(H1,"Y",F1:G1)+SUMIF(H1,"N",F1) -- Dave Peterson |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
SumIf Question
Try
=IF(H1="y",SUM(F1:G1),IF(H1="n",G1,"")) Mike "Ronda" wrote: I have a spreadsheet that I need to do a calculation if the answer is yes or "Y". I put the formula below in and it works correctly for the "N" formula. If the answer is "Y" the formula does not give me the sum of F1+G1 (actually "-" but I put the number in as a negative) but the total of F1 instead. =SUMIF(H1,"Y",F1:G1)+SUMIF(H1,"N",F1) |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Help Please SUMIF question | Excel Discussion (Misc queries) | |||
SUMIF question | Excel Worksheet Functions | |||
SUMIF Question | Excel Worksheet Functions | |||
SUMIF Question | Excel Worksheet Functions | |||
Sumif question | Excel Worksheet Functions |