Announcement

Collapse
No announcement yet.

Copy Rows & Insert At Bottom

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Copy Rows & Insert At Bottom

    i currently have a recorded marco that inserts four rows, highlights and copies a different four rows and pastes it (while deleting their values) in the rows that were inserted.

    the problem is that when i want to run the macro again, the four new rows that are inserted are in between the original four rows and the four rows that was pasted the first time the macro was ran.

    i'd like to have a macro that will paste the rows at the bottom of the list.

    the code currently look like:

    Code:
    Sub InsertRow()
    
    InsertRow Macro
    
    Rows("18:21").Select
    Selection.Insert Shift:=xlDown
    Rows("14:17").Select
    Range("C14").Activate
    Selection.Copy
    Rows("18:21").Select
    ActiveSheet.Paste
    Range("J18").Select
    Application.CutCopyMode = False
    ActiveCell.FormulaR1C1 = ""
    Range("J21").Select
    End Sub
    Any help would be greatly appreciated.
    Reply With Quote

  • #2
    Re: Insert Four Copied Rows At The Bottom

    Code:
    Sub InsertRow()
         
    
         
        Rows("18:21").Copy
        Cells(Rows.Count, "A").End(xlUp)(2, 1).Insert
        Application.CutCopyMode = False
    End Sub

    Comment

    Working...
    X