View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.misc
joel joel is offline
external usenet poster
 
Posts: 9,101
Default For Each VBA to sum

I would take a different appproach. I would copy al the data to a new sheet.
Then sort by employee and date. Then I would combine rows and delete
duplicates.. Put Sunday in Hours in column G, Monday in H, ...Saturday in M.
Then the total in column B would be the sum of H to M.

"jlclyde" wrote:

I am trying to use VBA to look at column A which is a date, column E
which is the employee number. then it is supposed to add other
columns up on the same rows. I want it to add them up if they are the
same week. For instance employee 1 worked 11-5-07 and 11-7-07. I
want to add up both occuerences. So their production is in B and C, I
want to add up all of the B that meet the A and E requirements. then
I want to delete the rows that made up the sum.

Thanks,
Jay