Posted By

joseamirandavelez on 06/09/12


Tagged

vba


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

joseamirandavelez
jfherring


Speed Up Excel Macro Execution


 / Published in: Visual Basic
 

Turn off screen updating, formula calculation and events in order to prevent Excel from doing all of them and speed up macro execution.

  1. Function turnEverythingOff()
  2. Application.ScreenUpdating = False
  3. Application.Calculation = xlCalculationManual
  4. Application.EnableEvents = False
  5. End Function
  6.  
  7. Function turnEverythingOn()
  8. Application.ScreenUpdating = True
  9. Application.Calculation = xlCalculationAutomatic
  10. Application.EnableEvents = True
  11. End Function

Report this snippet  

You need to login to post a comment.