Excel: Copy Array in 1 Workbook Paste Array in Another with LastRow


Not sure how to go about this process. I was hoping that someone could point me in the right direction. I need to copy and array of cells in one workbook and paste that array into another array of cells in the second workbook. Copy WorkBook is "Example" Paste Workbook is "Work"

Sub CopyPasteBetweenWB()
Dim Finalrow As Long
Dim i           As Integer
finalRow = ActiveSheet.UsedRange.Rows.count + 1
                                                       
CopyArray = Array( "I4", "C28", "K22", "M23", "F27", "M22", "K23")
PasteArray = Array(2,3,4,5,6,7,8)  'Final Row of Activesheet in "Work" Workbook in Respective Columns B, C, D, E, F ,G, H

 For i = LBound(CopyArray) To UBound(CopyArray)

Windows(Example).Activate
CopyArray(i).Copy
Windows(Work).Activate
.Range(finalRow & PasteArray(i) ).PasteSpecial xlPasteValues
Next i
End Sub
Not sure I am even on the right track. Any guidance with this issue would be great!!


This question generated 21 answers. To proceed to the answers, click here.

This thread is current as of July 11, 2014.


For more resources for Microsoft Excel