How to add previous sums in a column to current sums in a column?

G

Guest

I'm trying to build a workbook from project plan that keeps a running total
of actual hours. The only problem I'm having is with this summation
question. Numerous employees are entering their weekly hours for the current
week. How do I build a function that adds current weekly hours to the
previous weekly hours in my Actual hours column?

TD
 
G

Guest

What you probably need is a little macro that copys the current cumulative
total (previous hours + weekly hours reported) back up into the previous
hours cell and zeros out the weekly hours reported to use at the end of a
week.

Assume that the Previous Hours is kept in B5, that weekly hours for
employees are in C10 through C20, and the the cumulative total of all is in
D21, you could have code like this

Sub StartNewWeek()
Range("B5") = Range("D21")
Range("C10:C20")=0
Exit Sub
 

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