This macro works fine for copying and pasting totals: Sub Copy_Paste_Totals() ThisWorkbook.Worksheets("Sheet2").Select Dim LastRowTotal As Integer ThisWorkbook.Worksheets("Sheet2").Select LastRowTotal = Range("B65536").End(xlUp).Row ThisWorkbook.Worksheets("Sheet2").Select Range(Cells(LastRowTotal, 1), Cells(LastRowTotal, 13)).Select Selection.Copy Sheets("Brand Position").Select Range("B27").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Application.CutCopyMode = False End Sub
This macro is supposed to copy all details lines above the final total line - but I'm getting |------------------------------------------------------------------| |Run-time error '1004; | |Application-defined or object-defined error | |Sub Copy_Paste_Rows() | |______________________________________| ThisWorkbook.Worksheets("Sheet2").Select Dim LastRowTotal As Integer Dim LastRowData As Integer LastRowTotal = Range("B65536").End(xlUp).Row LastRowData = (Range("B65536").End(xlUp) - (1)) ThisWorkbook.Worksheets("Sheet2").Select Range(Cells(2, 1), Cells(LastRowData, 13)).Select Selection.Copy Sheets("Brand Position").Select Range("B17").Select Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _ :=False, Transpose:=False Application.CutCopyMode = False Any assistance is highly-appreciated. Thanks and all the best regards for the holiday season. Sanford Kadish -- ---------------------------------------------------------------------------------- Some important links for excel users: 1. Follow us on TWITTER for tips tricks and links : http://twitter.com/exceldailytip 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 3. Excel tutorials at http://www.excel-macros.blogspot.com 4. Learn VBA Macros at http://www.quickvba.blogspot.com 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com <><><><><><><><><><><><><><><><><><><><><><> Like our page on facebook , Just follow below link http://www.facebook.com/pages/discussexcelcom/160307843985936?v=wall&ref=ts