VBA Macros to insert a row at the end of a table, then paste values of previously copied lines in a specific range of the new row

lbradbury

New Member
Joined
May 14, 2020
Messages
46
Office Version
  1. 365
Platform
  1. Windows
I'm looking for help on a VBA Macros. This is my current code. Where the **** are I need some code to insert a row at the end of the table on the active worksheet, and then paste the values copied in the above code with the range of ("E1:R8") into the range (E?:R?") of the newly created row.

VBA Code:
`Sub Workbook()

Dim wb As Workbook
Set wb = Workbooks.Add

ThisWorkbook.Sheets("RFP Form").Copy Before:=wb.Sheets(1)
ThisWorkbook.Sheets("DataHelperSheet").Copy After:=wb.Sheets(1)
Application.DisplayAlerts = False

wb.SaveAs "Z:\Temp\test3.xlsx"

Application.DisplayAlerts = True

ActiveWorkbook.SaveAs FileName:="Z:\Temp\" & Range("I1").Value

Worksheets("DataHelperSheet").Activate
Range("E1:R8").Select
Selection.Copy

Workbooks("Proposal Quote Master List(LB).xlsm").Activate
Worksheets("Master List").Activate
***

Range("E1:R298").PasteSpecial Paste:=xlPasteValues


End Sub
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
How about
VBA Code:
Range("E" & Rows.Count).End(xlUp).Offset(1).PasteSpecial Paste:=xlPasteValues
 
Upvote 0

Forum statistics

Threads
1,224,748
Messages
6,180,721
Members
452,995
Latest member
isldboy

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top