Is there a way to lock a particular Google Apps worksheet using a script?
I have this code that renames the current spreadsheet to whatever you enter in the input box.
// The code below will rename the active sheet to what you enter in the input box
var myValue = Browser.inputBox("Enter: LastMonth - Year");
SpreadsheetApp.getActiveSpreadsheet().renameActiveSheet(myValue);
SpreadsheetApp.getActiveSpreadsheet().getRange("A1").setValue(myValue);
What can I add to the code above that will lock that same worksheet i just renamed only allowing me to edit that worksheet. Is that possible?