running totals between worksheets

R

rn2pacu

I need to keep track of the number of nights worked by an employee in a month
and then add that to the total for the next month's worksheet. Can anyone
help?
 
H

Harlan Grove

rn2pacu said:
I need to keep track of the number of nights worked by an employee in a month
and then add that to the total for the next month's worksheet. Can anyone
help?

Not unless you provide more details.

Generalities: if you have a column of start times and a column of end
times, which I'll refer to respectively as ST and ET, and every 8
hours worked between 6:00 PM and 6:00 AM counted as one night worked,
you could count number of nights worked in a given month using the
following array formula.

=SUM(IF(ET<ST,1-IF(ST<0.75,0.75,ST)+IF(ET>0.25,0.25,ET),
IF((ET<0.25)+(ST>0.75),ET-ST,IF((ST<0.25)+
(ET>0.75),IF(ET<0.75,0.25,ET)
-IF(ST>0.25,0.75,ST),0))))*3

You can carry a value from cell X99 in the worksheet named foo into
another worksheet using a reference like foo!X99.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top