loop

  • Thread starter Thread starter kimt
  • Start date Start date
K

kimt

Afternoon all,

I'm having some trouble with the code pasted below. It want's to debu
the Elseif statement, and I can't see why... any light you can shine a
the problem will be apreaciated.

Sub copyt()

Dim x As Range

x = Range("'data in'!S1")

Do
Sheets("blank timesheet").Select
Sheets("blank timesheet").Copy Before:=Sheets("finished")
Range("C2").Copy
Sheets("blank timesheet (2)").Select
Sheets("blank timesheet (2)").Name = "blank timesheet (2)"
Application.CutCopyMode = False
Sheets("data in").Select
Range("s2:al100").Copy
Range("s1").PasteSpecial xlPasteValues

Elseif


x.Offset(1, o0).Select
Loop Until x = " "

End Su
 
Why do you have ElseIf in there, there is no If statement that it
corresponds to?

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)
 
Hi
just delete the ElseIf statement. no reason for it to be there :-)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top