View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Stefi Stefi is offline
external usenet poster
 
Posts: 2,646
Default Speed of Execution

Try also to toggle
Application .Calculation = xlManual

Application .Calculation = xlAutomatic

Regards,
Stefi

€˛Mike H.€¯ ezt Ć*rta:

I have noticed that when my code comes to things like this:
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlBottom
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
that it slows WAY DOWN! At the start of the subs I have this:
Application.EnableEvents = False
Application.ScreenUpdating = False
Application.Cursor = xlWait
but it still is very slow. I am in a new workbook that I just added during
the execution. Would I need to execute the enableevents statement on the
newly added wb too or is the statement at time of beginning the calling sub
sufficient? Any ideas?