There's nothing in the formula that would return that. Is there a value
in J10:BM10 that has that error in it?
it seems like what is happening is the formula is trying to include all the
cells between J10 and BM10, but I only want to sum 12 specific cells in that
row (they're nonadjacent)--but it's very possible i just don't know the
formula language entirely. but to answer your question, yes, there are
several cells that have "div/0" in them, but they are among the cells that i
don't want involved in the formula. here are all the cells that I want to
eventually be included in the formula: J10 (Jan), O10 (Feb), T10 (Mar), Y10
(Apr), AD10 (May), AI10 (Jun), AN10 (Jul), AS10 (Aug), AX10 (Sep), BC10
(Oct), BH10 (Nov), BM10 (Dec). But the formula we're trying to come up with
should only sum the cells within that series that have already occured (Jan
through May, for now).
The rest of the cells in row 10 in between all these cells have formulas in
them that as of now are returning DIV/0 because those months haven't happened
yet and there is no data as of now (which is ok as far as I'm concerned; it
just messes up the year-to-date info).
This is where I'm having trouble. Thanks for all your help!
> There's nothing in the formula that would return that. Is there a value
> in J10:BM10 that has that error in it?
>
> > hmm...When I copy into the cell, it returns a "DIV/0!"
JE McGimpsey - 13 Jun 2007 18:12 GMT
Unless you want to hardcode each cell, you should trap the errors
instead of leaving them as "expected errors". This is good practice
anyway.
For example, instead of
P10: =N10/O10
where O10 may be zero, use
P10: =if(O10<>0,N10/O10,"")
SUM() (and SUMPRODUCT()) will then ignore the null string.
> This is where I'm having trouble. Thanks for all your help!
Sam - 13 Jun 2007 19:40 GMT
great! that worked as far as getting the SUMPRODUCT formula to bring back a
value. however, i'm still having trouble getting it to only sum specific
cells in that row. it's not returning an error, but it is adding everything
in that row. is there a way to select specific cells to sum together?
Thanks--this is a big help as it is and will be useful in many other
applications.
> Unless you want to hardcode each cell, you should trap the errors
> instead of leaving them as "expected errors". This is good practice
[quoted text clipped - 11 lines]
>
> > This is where I'm having trouble. Thanks for all your help!
JE McGimpsey - 13 Jun 2007 20:44 GMT
Yes, the second formula I gave you only sums every 5th column.
> great! that worked as far as getting the SUMPRODUCT formula to bring back a
> value. however, i'm still having trouble getting it to only sum specific
> cells in that row. it's not returning an error, but it is adding everything
> in that row. is there a way to select specific cells to sum together?