Hello,
I'm really hoping someone can help me with this. I have been working on it all day and I can't seem to get it to work. I need to use variables to reference and copy a range of cells.
I'm getting the following error with this code that I have been working on:
"Run-time error '1004': Method 'Range' of object '_Worksheet' failed"
Here is my code:
Please help!
I'm really hoping someone can help me with this. I have been working on it all day and I can't seem to get it to work. I need to use variables to reference and copy a range of cells.
I'm getting the following error with this code that I have been working on:
"Run-time error '1004': Method 'Range' of object '_Worksheet' failed"
Here is my code:
Code:
Sub test()Dim StartrowC1 As String
Dim EndrowC1 As String
Dim C1Selection As String
StartrowC1 = (ActiveCell)
EndrowC1 = (ActiveCell.Offset(8, 0))
Let C1Selection = StartrowC1 & ":" & EndrowC1
'Selection.Copy
Sheet18.Range(C1Selection).Select
'and that's as far as I can get at the moment :(
End Sub
Please help!