Excel function help
Try a simple if function and use the results as your carry foreward
subtotal.
in D12 enter .....=IF(C12=0,70,70-C12)
in D13 enter .....=IF(C13=0,70,D12-C13)
extend D13 down to D19 using the right hand bottom corner of d13.
Trying Bob's example, it looks like you have to have all the days filled in
before you get a answer.
Greetings from New Zealand
"Bob Phillips" wrote in message
...
Try
=SUM(C19:INDEX(C12:C19,MAX(IF(C12:C19=0,ROW(C12:C1 9)))-ROW(C12)+1))
as an array formula, so commit with Ctrl-Shift-Enter, not just Enter.
--
---
HTH
Bob
(change the xxxx to gmail if mailing direct)
"wvhilltop" wrote in message
...
I am working on a spread sheet for truck drivers. I have then columns set
up
with the drivers names and hours of work. The rows are broke up into
days of
the week. Drivers are only allowed to driver 70 hours in 8 days. I have
the
spread sheet set so the column is subtracting the given hours from the 70
to
show how many hours are left in the prior 8 day period. Only problem is
when
I driver doesn't work the time needs to reset to the available 70. I
have an
IF formula that is working, but it is set to count the days above the
last
zero. How can I have it stop that?
=IF(C19=0,-70,c19+c18+c17+c16+c15+c14+c13+c12-70)
I need to get it to stop counting above the last zero.
|