View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Chip[_3_] Chip[_3_] is offline
external usenet poster
 
Posts: 133
Default Help with updating formulas

If it is always from 50 cells down from where the formula is put in,
then this should work:

Function sum50()

currentrow = ActiveCell.Row
currentcolumn = ActiveCell.Column
sumtotal = 0
Do Until IsEmpty(Cells(currentrow + 50, currentcolumn))
sumtotal = Cells(currentrow + 50, currentcolumn).Value + sumtotal
currentrow = currentrow + 50
Loop
sum50 = sumtotal
End Function