Try this (untested but compiled OK)
Sub Test()
Dim shtCopy As Worksheet
Dim shtPaste As Worksheet
Dim rowcopy As Long, numrows As Long
Set shtCopy = ThisWorkbook.Sheets("All Transfer Data F24.89_3")
Set shtPaste = ThisWorkbook.Sheets("Paste Data")
rowcopy = 14
numrows = shtCopy.Rows.Count
Do While shtCopy.Cells(rowcopy, 5).Value < ""
If shtCopy.Cells(rowcopy, 13).Value = "" Then
shtCopy.Rows(rowcopy).Copy _
Destination:=shtPaste.Cells(numrows,
2).End(xlUp).Offset(1, -1)
End If
rowcopy = rowcopy + 1
Loop
End Sub
Tim
"GB900180" wrote in
message ...
Guys,
First time on here & I'm a bit of a VBA newbie. I'm trying to
construct a pretty simple macro to scroll down through the contents of
a worksheet and where a given cell is "" to take the entire rows
contents to another sheet. So far I'm up to here ...
RownumberEndWorksheet = 14
Do Until Sheets("All Transfer Data
F24.89_3").Cells(RownumberEndWorksheet, 5) = ""
If Sheets("All Transfer Data F24.89_3").Cells(RownumberEndWorksheet,
13) = "" Then
At this point I've nominated all the individual cells to be taken from
"All Transfer Data F24.89_3" by specifying
cells(RownumberEndWorksheet, applicable column ref). This is tedious
as there's lots. Then I look to the sheet to paste data & find the
next available line as follows ;
RownumberNext = 5
Do Until Sheets("Paste Data").Cells(RownumberNext, 2) = ""
RownumberNext = RownumberNext + 1
Loop
Worksheets("Paste Data").Cells(RownumberNext, 2) = VarBarcode
etc.
Please can someone show me how to select the entire contents of a row
when I've found one whe
If Sheets("All Transfer Data F24.89_3").Cells(RownumberEndWorksheet,
13) = ""
and then get the data in to the paste sheet.
I'm sorry this is probably childs play to someone with some experience
but I'm struggling here. Much appreciated in
advance!!!!!!!!!!!!!!!!!!!!
--
GB900180
------------------------------------------------------------------------
GB900180's Profile:
http://www.excelforum.com/member.php...o&userid=30423
View this thread: http://www.excelforum.com/showthread...hreadid=501905