I’ve created a leave diary for my teams, but I want to create a button to allow to add new members. I have a template row stored on one sheet titled code on row 4 that I want to copy and insert in the next available line whilst keeping a break between the next line with data in on another sheet. Ie line 1:5 staff 6 is blank 7 is other info so when it inserts the new line with the data it will insert it into line 6 then create a blank row for line 7 and move all other rows down one. I want to keep the formulas and conditional format that has been coded into the template line I am copying. I keep getting an error on the first line of code?
ThisWorkbook.sheets(“code”).row(4).copy
ThisWorkbook.sheets(“sheet3”).range(“A1”).end(xlDown).offset(1,0).entirerow.insert