Copy rows from one sheet to another

Closed
rickl138 - Jan 30, 2011 at 08:10 PM
rizvisa1
Posts
4479
Registration date
Thursday January 28, 2010
Status
Contributor
Last seen
May 5, 2022
- Feb 9, 2011 at 05:18 PM
Hello,

I have two workbooks;
Workbook 1 has 12 rows
Workbook 2 has 12 worksheets that contains the pasted weekly results from worksheet 1.
I am trying to figure out how to copy row 1 to the first blank row in workbook2 sheet 1, row 2 into the first blank row in workbook2 sheet 2, etc.
Thaks
Rick

1 reply

rizvisa1
Posts
4479
Registration date
Thursday January 28, 2010
Status
Contributor
Last seen
May 5, 2022
769
Feb 9, 2011 at 05:18 PM
find the used row of the sheet where you want to copy

lastRow = Cells(rows.count, "A").end(xlup).row

presuming that if a row has a data then column A will always have data
the above formula gives you the last used row (unless the sheet is empty then it gives the row #1)
0