Use Macro to replace =sum() for large amount of data

SheldonCooper

New Member
Joined
Jun 5, 2013
Messages
1
Hi,


This is what I currently have
:


Google Drive:
https://docs.google.com/file/d/0B89c...it?usp=sharing


I currently have =sum() formula in the STARTING from the column range:
EA101 --> =SUM(CA101:CA105) <<sum of="" 5="" rows="">></sum>
Drag to autofill across, and to bottom, 4 rows above the data source (DA101:DW421). Otherwise, it will sum blank cells.

GA101 --> =SUM(CA101:CA106) <<sum of="" 6="" rows="">></sum>
Drag to autofill across, and to bottom, 5 rows above the data source (DA101:DW421). Otherwise, it will sum blank cells.

iA101 --> =SUM(CA101:CA110) <<sum of="" 10="" rows="">></sum>
Drag to autofill across, and to bottom, 9 rows above the data source (DA101:DW421). Otherwise, it will sum blank cells.

KA101 --> =SUM(CA101:CA115) <<sum of="" 15="" rows="">></sum>
Drag to autofill across, and to bottom, 14 rows above the data source (DA101:DW421). Otherwise, it will sum blank cells.

MA101 --> =SUM(CA101:CA120) <<sum of="" 20="" rows="">></sum>
Drag to autofill across, and to bottom, 19 rows above the data source (DA101:DW421). Otherwise, it will sum blank cells.



The Sample excel I have uploaded only consists of 321 rows (CA101:DW421).
However, the actual data (multiple sets of data) that I have consists of 300000+ rows.


As a result, the =sum() function that I have takes too long to caculate/out of memory everytime I provide new data from CA101:DW.


I am wondering if there is a faster way, maybe a macro, that could do the calculation instead of using the formlua?



Thanks,

Sheldon
 

Excel Facts

Quick Sum
Select a range of cells. The total appears in bottom right of Excel screen. Right-click total to add Max, Min, Count, Average.
Cross-posted and answered here to save everyone time.
 
Upvote 0

Forum statistics

Threads
1,215,575
Messages
6,125,618
Members
449,238
Latest member
wcbyers

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top