M
mwc0914
I want to copy a series of cells from wkbk to another, but I need to do
it one cell at a time (because of some additional processing) instead
of just a straight select/copy/paste. How do I define the range of
cells in my destination workbook so I can copy to them. I need to open
the destination wkbk & define the destination cells. This code kind of
gives the idea...
Sub Macro1()
Dim ocells As Range
Set ocells = Range("a1:a5")
Dim nwkbk As Workbook
Set nwkbk = Workbooks.Open(ThisWorkbook.Path & "\Book2.xls")
dim ncells as range
set ncells = ??????
For i = 1 To 5
ncells(i) = ocells(i) ' How do I do this across wkbks then save
nwkbk
Next i
nwkbk.Save
nwkbk.Close
End Sub
it one cell at a time (because of some additional processing) instead
of just a straight select/copy/paste. How do I define the range of
cells in my destination workbook so I can copy to them. I need to open
the destination wkbk & define the destination cells. This code kind of
gives the idea...
Sub Macro1()
Dim ocells As Range
Set ocells = Range("a1:a5")
Dim nwkbk As Workbook
Set nwkbk = Workbooks.Open(ThisWorkbook.Path & "\Book2.xls")
dim ncells as range
set ncells = ??????
For i = 1 To 5
ncells(i) = ocells(i) ' How do I do this across wkbks then save
nwkbk
Next i
nwkbk.Save
nwkbk.Close
End Sub