Question : excel vba add sheet
Answered by : vastemonde
Sheets.Add
Sheets.Add After:=Sheets("Input")
Sheets.Add After:=Sheets(1)
Sheets.Add Before:=Sheets(2)
Sheets.Add.Name = "NewSheet" ' Add sheet with name
Sheets.Add After:=Sheets(Sheets.Count) ' To end of Workbook
Sheets.Add(Before:=Sheets(1)).Name = "FirstSheet" ' To beginning of Workbook
Source : https://www.automateexcel.com/vba/add-and-name-worksheets/ | Last Update : Tue, 18 May 21
Question : excel vba protect sheet
Answered by : vastemonde
'Apply worksheet protection to contents, objects and scenarios
Sheets("Sheet1").Protect Password:="myPassword", _ DrawingObjects:=True, _ Contents:=True, _ Scenarios:=True
Source : https://exceloffthegrid.com/vba-code-worksheet-protection/#Protect_objects | Last Update : Fri, 02 Apr 21