View Single Post
 
Old 09-18-2019, 09:09 PM
gmayor's Avatar
gmayor gmayor is offline Windows 10 Office 2016
Expert
 
Join Date: Aug 2014
Posts: 4,106
gmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud ofgmayor has much to be proud of
Default

I prefer not to use exit sub, but goto a label at the end of the macro where the macro is tidied up e.g. as follows

Code:
Sub Macro1()
Dim orng As Range
    Application.ScreenUpdating = False
    ' code of macro
    GoTo lbl_Exit
    ' more code
lbl_Exit:
    Application.ScreenUpdating = True
    Set orng = Nothing
    Exit Sub
End Sub
I cannot comment on the CPU use.
__________________
Graham Mayor - MS MVP (Word) (2002-2019)
Visit my web site for more programming tips and ready made processes www.gmayor.com
Reply With Quote