google apps script: remove and restore protection
问题 I have a spreadsheet that is editable by everyone with a protected sheet with some ranges unprotected. I want cells that can be altered by a script run by any user (from a menu), but not manually. When I run the script not as the owner it gives an error message when I try to temporarily remove the protection. 回答1: There seems to be no easy way to do this, because functions run from the menu is always executed as "user at the keyboard". One workaround is to publish a Web App to always "Execute