View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Frank Situmorang Frank Situmorang is offline
external usenet poster
 
Posts: 97
Default For Each ...next..

Paul:

My macro stucked in the Range.Copy Stage, I do not know why. could you
explain whiy after finishing copy the named ranges it stuched there?

Sorry maybe my English is not good, because we seldom use English in
Indonesia.

Thanks in advance,


Frank Situmorang

" wrote:

Sorry, I've no idea at all what you want.
regards
Paul

On May 11, 9:04 am, Frank Situmorang
wrote:
Dear experts:

How can we stop the looping using For each... ..next. It worked for me
perfectly, but it stuck in the Range x. Copy after it finished copying all my
defined range name.

Here is my macro:
Sub AutoShape7_Click()
' Macro recorded 5/10/2007 by Frank
'
'
ActiveWindow.SmallScroll ToRight:=-5
Range("A9:Y1714").Select
Selection.ClearContents
Dim x As Object
For Each x In ActiveWorkbook.Names
Range(x).Copy
Sheets("SUMMARYWBLA").Select
Range("a65000").End(xlUp).Offset(1, 0).PasteSpecial xlPasteAll
Next x
End Sub
Many thanks to all of you that had helped me

Frank