nesting more than 7 functions?
Roger, your formula is very close. It is adding the first three columns in
WS2 but it is adding those cells even though the values of A1:C1 were 0. It
should not add any values in WS2 unless there is a value 0 in A1 or B1, or
C1 etc.
Roger, your second formula gave the message "a value used in the formula is
of the wrong data type".
Thanks again for trying to help with this.
--
Brian
"Roger Govier" wrote:
Hi Brian
maybe
=SUM(WS2!$A$1:INDEX(WS2!$A1:$L1,COUNT($A1:$L1)))
--
Regards
Roger Govier
"Brian" wrote in message
...
You are correct in your assumption. Cells A1:L1 represent 12 months Jan-
Dec
2009, cell M1 is the total and N1 is a year to date total that is linked
to
WS2 which is the exact same spreadsheet however it is the 2008 schedule.
N1
should add the months from 2008 if the same month(s) in 2009 have been
entered. Example, if Jan and Feb 2009 have values $1000 and March to Dec
are 0 then N1 should be the sum of Jan and Feb of 2008 (A1+B1) of WS2. I
hope
this gives enough information to do a formula. Thanks again for your help.
--
Brian
"JBeaucaire" wrote:
Yes, it's possible. It looks like you're trying to adjust your sum range
based on how may cells have data in the row you're working on. True?
Then perhaps some sort of =ADDRESS function or INDIRECT function would
allow
you to identify the first (last?) cell with data and create the sum range
from W2 in a single step rather than 8 individual checks.
Would need more info about the values in the cells being checked and the
complete set of "results" to make sure we get it right.
--
"Actually, I *am* a rocket scientist." -- JB
Your feedback is appreciated, click YES if this post helped you.
"Brian" wrote:
I am using the following formula but it will involve nesting 12
functions. I
understand the limit is 7. Is there a way to write the formula to avoid
the
nesting restriction? The first part of the formula is below and it
needs to
continue from sum(A1:K1) to sum(A1:J1) to sum(A1:I1) and so on 12
times
until it reaches A1.
=if(L10,'WS2'!M1,if(K10,sum('WS2'!A1:K1),if(J10 ,sum('WS2"!A1:J1)...
(and
so on),0)))))
Thanks for your help.
--
Brian
|