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:
Any help would be greatly appreciated.VB: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
Reply With Quote
VB:Sub InsertRow() Rows("18:21").Copy Cells(Rows.Count, "A").End(xlUp)(2, 1).Insert Application.CutCopyMode = False End Sub
There are currently 1 users browsing this thread. (0 members and 1 guests)