I am using the code bellow to copy across data contained in rows in columns e,f & g only if there is data in column f for that row:
It works but it currently copies each row in turn, which just slows the process down a bit. So I was hoping to group all the rows together so they copy across in one go but I am unsure how to do this...any ideas?
Sub OpenRecordForm_Discrepancies()
Dim i As Long, x As Range
With Sheets("Discrepancies")
For i = 6 To .Range("g" & Rows.Count).End(xlUp).Row
Set x = .Cells(i, "e").Resize(, 3)
If .Cells(i, "f").Value = "" Then
Exit Sub
Else: x.Copy
Sheets("Upload Sheet").Range("a" & Rows.Count).End(xlUp)(2).PasteSpecial _
Paste:=xlPasteValues
End If
Next
End With
Thanks in advance,
Strud
Bookmarks