Is there a way to "lock" some cells in a notebook so they can't be edited? It's usually input cell that's documenting some functionality. I'd like other readers of the notebook to be able to execute them but not changing them.
Suppose you have an open notebook, say "Untitled-1". The following code, executed in the same notebook or another, will select all the Input cells and set them to un-Editable and un-Evaluatable.
nb = First[Notebooks["Untitled-1"]]; inputCells = NotebookFind[nb, "Input", All, CellStyle]; SetOptions[inputCells, Evaluatable -> False, Editable -> False]