-
Excel VBA problems
When trying to run the following piece of code I get a runtime '1004' error, select method of range class failed.
I am trying to copy a selection of data from one sheet to anoher sheet and then moe the row down.
The code I have is as follows:
Range("c33:d33").Select
Selection.Copy
Sheets("examples2").Select
Range("B3:C3").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Selection.Insert Shift:=xlDown
It keeps falling over at the section in bold, if anyone has any answers, much appreciated thanks. Have looked fro other solutions on other websites but doesnt seem to help.
-
Are you trying to copy a value form one field to another?
if so try
Sheets("examples2").Range("B3").Select = _
Sheets("WHAT EVER THIS CALLED").Range("C33").value
Sheets("examples2").Range("C3").Select = _
Sheets("WHAT EVER THIS CALLED").Range("D33").value