Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default looping through worksheets

I have problem looping through worksheets. I am getting
error 9. Please help.This is my code:
Sub copy2()
Dim update As Range
Dim cell As Range
Dim a As String
Dim i As Integer
Dim b As String
For i = 1 To 3
Set cell = Workbooks("0620.Xls").Sheets("d.o.").Range
("c27").Offset(0, 1)
a = Str(i)
b = "control_point" & a
Set update = Workbooks("0620.Xls").Sheets(b).Range("d26")
update.copy
cell.PasteSpecial Paste:=xlPasteValues, _
Operation:=xlNone, _
SkipBlanks:=False, Transpose:=False
Next i
End Sub
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Looping Maggie[_6_] Excel Discussion (Misc queries) 6 October 2nd 08 09:14 PM
finding & looping Jase Excel Discussion (Misc queries) 0 May 13th 08 08:01 PM
Looping Macro Jase Excel Discussion (Misc queries) 5 March 12th 08 09:08 PM
Not Looping Roger Excel Discussion (Misc queries) 0 February 26th 08 05:18 PM
Looping David T Excel Discussion (Misc queries) 2 August 30th 06 10:51 PM


All times are GMT +1. The time now is 12:13 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"