Trying to paste underneath all the data on a different workbook but am getting application defined error
Edit:
Sub Matt_Liam()
Dim Rng As Range
Set Rng = Workbooks("orders (3).xlsx").Worksheets("Sheet3").Range("A1:AY300")
Rng.Copy
Dim i As Long
Dim s11 As Workbook
Set s11 = Workbooks("11 Production")
Set s11 = ActiveWorkbook
With Sheets("Sheet1")
If Application.WorksheetFunction.CountA(.Cells) <> 0 Then
lastRow = .Cells.Find(What:="*", _
After:=.Range("A1"), _
Lookat:=xlPart, _
LookIn:=xlFormulas, _
SearchOrder:=xlByRows, _
SearchDirection:=xlPrevious, _
MatchCase:=False).Row
Else
lastRow = 1
End If
End With
Rng.PasteSpecial
End Sub
The errors are here
Range(Selection, Selection.End(xlDown)).Select
And Here
Workbooks("11 Production.xlsx").Worksheets("Sheet1").Range("A" & i).Select