View Single Post
  #4   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson[_5_] Dave Peterson[_5_] is offline
external usenet poster
 
Posts: 1,758
Default Opening/Closing a lot of groupings via VBA

maybe this'll help:

XL: "Cannot Shift Objects Off Sheet" Error Hiding Columns
http://support.microsoft.com/default...b;en-ca;211769

(It sounds kind of like it may match your translation.)

Dirk Flakowski wrote:

Hello Dave,

thanks for your answer. With that I have one problem: All rows and
columns which are not used are hidden and the worksheet contains a lot
of comments. Then on using that statement I get the following error (I
try to translate the German message):
"Objects can't be moved over the border"

So before using the statement I have to make a few rows/columns
visible, execute the statement and then make them invisible again.
That works fine but then it also takes quite long - especially on
closing all as I have to execute the statement there 8 times (once for
each level) so that really all groupings are closed.

Thanks
Dirk

On Wed, 15 Dec 2004 20:57:28 -0600, Dave Peterson
wrote:

You're hiding all or showing all???

If yes, then how about just doing it twice:

ActiveSheet.Outline.ShowLevels 1

and later:

ActiveSheet.Outline.ShowLevels 8

If you wanted to just see some of the outline, I can see why you'd want to
loop--but not all or one.




--

Dave Peterson