Aug 28 2022 03:50 AM
Hello everyone,
I am trying to create a macro that adds specific rows in Excel/at a specific position. For visualization see screenshot below.
Basically what I´m trying to do is by clicking "button 3" I want Excel to add the rows 9-11 (see highlight in green-ish) as of line 13 with the same formatting plus the dropw-down field (highlighted in organge). Obviously, when clicking "button 3" again the three rows should be added as of row 17. The idea would be to have one row in between.
Thanks a lot in advance for your support - much appreciated.
Aug 28 2022 04:12 AM
Sub Button3_Click()
Dim r As Range
Set r = Range("A" & Rows.Count).End(xlUp).Offset(2)
Range("A9:J11").Copy Destination:=r
Application.CutCopyMode = xlCopy
End Sub
Sep 05 2022 10:34 AM
@Hans Vogelaar : fantastic - thanks a lot