How to clear Excel Memory with VBA w/o closing the application?

stastim

Board Regular
Joined
Aug 9, 2004
Messages
89
Hi,
I use a 3rd party add-in to download a bunch of data. If I try to download the entire data set my Excel gets frozen, so I use a loop statement to download one section at a time. With each step (500 rows), the Memory that Excel uses rises significantly reaching 1.4GB in no time, at which time I can't save the spreadsheet - the message pops up saying that I don't have enough resources to save the file. Even after I close the spreadsheet, the 1.4Mb of memory is still showing up in the Task Manager (with just Excel shell and no files). Can I do something with VBA to keep the Memory use low so that I could finish my data download and actually save the file? Any other ideas?

Thanks!
 

Excel Facts

Can you AutoAverage in Excel?
There is a drop-down next to the AutoSum symbol. Open the drop-down to choose AVERAGE, COUNT, MAX, or MIN

Forum statistics

Threads
1,224,586
Messages
6,179,729
Members
452,939
Latest member
WCrawford

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