Hi, I'm not sure why the following code threw the error. Please advice, thanks!
VBA Code:
Sub Overview()
Dim i As Range
Dim pur As Worksheet
Dim report As Worksheet
Set pur = Worksheets("Purchase")
Set report = Worksheets("Report")
For i = 3 To 1000
If pur.Range("AF" & i).Value = "Y" Then
pur.Range("Z" & i).Copy
report.Range("A" & Rows.Count).End(xlUp).Offset(1, 0).PasteSpecial xlPasteValue
End If
Next i
End Sub