How do you stop calculating when running a macro?

B

BZeyger

I have a large report in which I perform numorious sorts. The report takes a
long time to create because after every sort, it goes through the
calculations. Is there a way to run the report without it calculating until
the very end?
 
J

JE McGimpsey

One way:

Wrap your code with

Application.Calculation = xlCalculationManual

<your code here>

Application.Calculation = xlCalculationAutomatic
 
J

John.Greenan

Also, switch application.screenupdating=false at the beginning and switch it
back to true at the end - that will speed things up as well.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top