Thread
:
Copy every 3rd cell, define destination range for paste
View Single Post
#
2
Posted to microsoft.public.excel.programming
Don Guillett
external usenet poster
Posts: 10,124
Copy every 3rd cell, define destination range for paste
See your ORIGINAL thread
--
Don Guillett
SalesAid Software
"Meltad" wrote in message
...
Hi all,
I'm trying to copy every third cell of column c starting at C16, and paste
into column C of the next blank row of a separate workbook. This code
below
kind of works but it errors where I've defined the 'pasterange' in the
other
workbook (I think this is incorrect but you know what I'm trying to
achieve!). Can anyone help?? :-) Also I don't know how to set the code to
copy from C16 to nrows - if it copies from the bottom i need to go up a
row,
copy that, then copy every 3rd. Column C looks like this...
35467 <---- (Row 16)
text 1
BLANK
84950
text 2
BLANK
24967
text 3
BLANK
I need all the numbers... Code below
Dim pasterange As Range
Dim i As Long
Set pasterange =
Windows("LFmacro.XLS").Sheets("Report").Range("A65 536").End(xlUp).Offset(2)
LastRow = Cells(Rows.Count, 3).End(xlUp).Row
For i = 1 To LastRow Step 2
pasterange = Cells(i, 1)
Next i
Reply With Quote
Don Guillett
View Public Profile
Find all posts by Don Guillett