View Single Post
  #7   Report Post  
Posted to microsoft.public.excel.programming
Peter T Peter T is offline
external usenet poster
 
Posts: 5,600
Default 2007 Merge cells taking forever

Thanks. I forgot to ask last time but are you using Vista.

For your purposes you shouldn't need to disable calculation unless anything
you are doing triggers or requires a recalc. Typically if merely merging
cells that's not the case. Though If you are doing very many merges you
might want to disable screenupdating.

Regards,
Peter T

"J Streger" wrote in message
...
It is turned off. I run this method at the start of every entry point:

Public Sub ScreenUpdating(Optional bEnable As Boolean = True)

Application.ScreenUpdating = bEnable
Application.Calculation = IIf(bEnable, xlCalculationAutomatic,
xlCalculationManual)
Application.Interactive = bEnable
Application.EnableEvents = bEnable
ThisWorkbook.Running = Not bEnable

End Sub 'ScreenUpdating


--
*********************
J Streger
MS Office Master 2000 ed.
MS Project White Belt 2003

User of MS Office 2003



"Peter T" wrote:

Just curiosity, is calculation dis/enabled during the process

Regards,
Peter T

"J Streger" wrote in message
...
It seems that every time I try to merge cells via VBA, it takes
forever.
Code
that ran in 1 second in 2003 is taking over 10 seconds in 2007, and
Excel
is
stating it is Not Responsive so even the status bar is not updating. I
tried
to pull all of the merging out of my loop and do it in one line,
thinking
that this would be faster, but alas it seems the merging time is
proportonal
to the amount of sections I'm merging. Anyone else have this issue and
know
how to fix?

--
*********************
J Streger
MS Office Master 2000 ed.
MS Project White Belt 2003

User of MS Office 2003