ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Merging two workbooks (https://www.excelbanter.com/excel-programming/293687-merging-two-workbooks.html)

Fred Smith

Merging two workbooks
 
I'm trying to merge two workbooks.

I select the next available row in my Bookname workbook by:

Range("A2").End(xlDown).Offset(1, 0).Select

Then I open the other workbook, determine the range and say:

Sheets("Sheet1").Range("A1").CurrentRegion.Copy _
Destination:=BookName.ActiveSheet.ActiveCell

But VBA doesn't like my destination. How do I specify the currently selected
cell in my destination workbook? Or, alternatively, the first free row (the
one after xldown)?

--
Thanks,
Fred
Please reply to newsgroup, not e-mail





All times are GMT +1. The time now is 07:20 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com