copying and pasting range of cells but only values to new workbook after last line. My copy worksheet data range starts at o3 and goes to r100. data will change. the new work book where i want to start pasting just the values starts at cell m13. by clicking button i want pull new data under a blank line.
I have researched code that either does copy and paste to different workbooks or copying to last row. but not both.
Sub xtrnsf_to_other_wrkbook()
'Find the last used row in both sheets and copy and paste data below existing data.
Dim wsCopy As Worksheet
Dim wsDest As Worksheet
Dim lCopyLastRow As Long
Dim lDestLastRow As Long
'Set variables for copy and destination sheets
Set wsCopy = Workbooks("LP sort2.xlsm").Worksheets("Chalks")
Set wsDest = Workbooks("PC.xlsm").Worksheets("Planner's Checklist")
'1. Find last used row in the copy range based on data in column A
lCopyLastRow = wsCopy.Cells(wsCopy.Rows.Count, "O").End(xlUp).Row
'2. Find first blank row in the destination range based on data in column A
'Offset property moves down 1 row
lDestLastRow = wsDest.Cells(wsDest.Rows.Count, "M").End(xlUp).Offset(2).Row
'3. Copy & Paste Data
wsCopy.Range("O3:R).Copy _
wsDest.Range("M" & lDestLastRow)
End Sub
My copy worksheet data range starts at O3 and goes to r100. data will change. the new work book where i want to start pasting just the values starts at cell M13. by clicking button i want pull new data under a blank line.