We'd need to know the full table array address and what nth column you're trying to return.
Where are these reports? Are they different files or different tabs? Where do the values you're looking up begin in K? When you output to the new workbook, where do you want them?
Assuming you provide the necessary details, something along the lines of:
Sub More()
Workbooks.Add
ActiveWorkbook.SaveAs ("C:\blah.xlsx")
Dim wbDet As Workbook: Set wbDetail = Workbooks("Detail.xlsx")
Dim wbInv As Workbook: Set wbInv = Workbooks("Inventory.xlsx")
Dim wbBlah As Workbook: Set wbBlah = Workbooks("blah.xlsx")
For i = 1 To wbDet.Sheets("Sheet1").Range("K" & Rows.Count).End(xlUp).Row
wbBlah.Sheets("Sheet1").Range("A" & i) = WorksheetFunction.VLookup(wbDet.Sheets("Sheet1").Cells(i, "K"), _
wbInv.Sheets("Sheet1").Range("A2:R500"), 18, 0)
Next
End Sub
Bookmarks