How to copy rows to a new worksheet if column F is not blank

eileendenver

New Member
Joined
Dec 14, 2005
Messages
5
I would like to copy rows to a new worksheet if column F (date of completion) is not blank. I would also like to copy over the headings if possible.

I will greatly appreciate your help since I have very limited VBA experience.
Thank you, in advance.
 

Some videos you may like

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

SteveO59L

Well-known Member
Joined
Apr 21, 2004
Messages
7,896
Something like,

Dim c As Range, rng

Set rng = Range("a1:a" & Range("a65536").End(xlUp).Row)
For Each c In rng
If c.Value <> "" Then
Rows(c.Row).EntireRow.Copy Sheets("Sheet1").Range("a" & Sheets("Sheet1").Range("a65536").End(xlUp).Row + 1)
End If

Next c

change references to suit.
 

Watch MrExcel Video

Forum statistics

Threads
1,118,020
Messages
5,569,678
Members
412,287
Latest member
Ardamit
Top