Calculate intermediate total on page change and carry it over.

R

Rahul Gupta

I am using excel 2003 sp2 on my system.

Now I want to insert total of two column every time page changes like one
below:

1
3
3
 
R

raypayette

Your problem was interesting!
Suppose that your print pages are 52 rows long, add this code in
ThisWorkbook:
Private Sub Workbook_BeforePrint(Cancel As Boolean)
For i = 1 To 3
a = i * 52
Cells(a, 2) = "=Sum(C1:C" & a & ")"
Next
End Sub
Of course you can add variations.
 
Top