I am trying to have a macro, on command, find the last used cell in Column A and then insert 2 rows before the 5 rows preceding that last cell.
I have found the following code on stackoverflow for finding the last used cell, but have not been able to use this to add 2 rows.
Dim LastRow As Long
' Find the last row in column "C" (pass in whatever column you want, obviously)
LastRow = Range("A" & ActiveSheet.Rows.Count).End(xlUp).Row
rw = LastRow - 5
Just add this line