Thread: Updating a sum
View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett Don Guillett is offline
external usenet poster
 
Posts: 10,124
Default Updating a sum

Hard to say without seeing your layout and macro and formulas. Have you
tried just using sumproduct

=sumproduct((month(a2:a22)=1)*b2:b22)
for the week have a look in the help index for WEEKNUM

--
Don Guillett
SalesAid Software

"newguy" wrote in message
oups.com...
I having trouble getting my macro to do what I need it to do. I have a
sheet where a user inputs data for the day it then goes to a worksheet
for the corresponding day. For each day there is a budget that I have
a macro that puts it in based on the day of the week. My problem is I
need to total these up for the week and for the month on each page. So
if it is the 1st of the month the budget for the day week and month are
all the same. But on the second the week and month are added to the
previous day. Then when the week is over the month will continue to
accumulate but the week will be reset. I have tried recording the
macro but was unsuccessful in my attempt. Thank You