G
Greg Snidow
Greetings folks. I need to cut the active row from one sheet, and paste it
into the first blank row in another sheet. So far this is what I have, and I
am not sure how to do it. I can activate the target row, but I am unable to
paste into it. Any ideas? Thank you.
Dim WS As Worksheet
Dim LastRow As Integer
'Cut the active row from the present sheet
ActiveCell.EntireRow.Cut
'Set the target sheet
Set WS = ActiveWorkbook.Sheets!held
'Set start row of the destination sheet
LastRow = 8
With WS
'Get the first blank row on destination sheet
For i = 8 To 300 Step 1
If Len(.Cells(i, 4).Value & "") > 0 Then
LastRow = LastRow + 1
End If
Next i
'Need to paste the row that was cut from the previous sheet
'This is where I am getting errors.
.Cells(LastRow, 1).Paste
End With
'WS.Activate
Greg
into the first blank row in another sheet. So far this is what I have, and I
am not sure how to do it. I can activate the target row, but I am unable to
paste into it. Any ideas? Thank you.
Dim WS As Worksheet
Dim LastRow As Integer
'Cut the active row from the present sheet
ActiveCell.EntireRow.Cut
'Set the target sheet
Set WS = ActiveWorkbook.Sheets!held
'Set start row of the destination sheet
LastRow = 8
With WS
'Get the first blank row on destination sheet
For i = 8 To 300 Step 1
If Len(.Cells(i, 4).Value & "") > 0 Then
LastRow = LastRow + 1
End If
Next i
'Need to paste the row that was cut from the previous sheet
'This is where I am getting errors.
.Cells(LastRow, 1).Paste
End With
'WS.Activate
Greg