# How to edit a downloaded cdf textbook example or prevent someone from editing my notebook?

I have downloaded from https://www.wolfram.com/cdf/uses-examples/textbooks.html the textbook example and I have opened it. I am trying to make some edits but I cannot. I opened the option inspector and all the Editable options are on True. Can anybody tell me how to edit it or, oppositely, how to prevent someone from editing my notebook?

• thanks, so with regard to preventing me and others to edit a notebook when it is believed to be in the final version a good way would be using Option Inspector and untick editable? – Andrea G May 8 '17 at 9:19
• everything depends on your goals. Which CDF you what to edit and why? Do you want to use nice snippets for your own code? – garej May 8 '17 at 9:46
• I was more concerned on learning how to "block" a code and text so that it cannot be changed. I noticed that the options of the abovementioned downloaded cdf were on true (editable) so I was wondering if there was some other trick – Andrea G May 8 '17 at 9:49

## 1 Answer

This should do:

nb = Import["path/to/BriggsCochraneCalculus.cdf"];
nb = NotebookPut@nb;
SetOptions[nb, Deployed -> False, Editable -> True]


You can now save it as .nb somewhere.

Why Options Inspector does not work? I must say I don't know but here's a guess.

One could expect that

nb = NotebookOpen @ "path/to/BriggsCochraneCalculus.cdf"

SetOptions[nb, Editable -> True, Deployed -> False, StyleDefinitions -> "Default.nb"]


should make it possible to edit the notebook, those options itself are applied (can be confirmed with Options).

The only one thing that comes to my mind is Notebook Signature.

Each cdf contains a footer similar to:

(* NotebookSignature 7KNa5d9r5bEV5L5WXOW32XP4 *)

The signature is used by the FrontEnd to check whether a CDF was edited outside mathematica.

Additionaly it stores information about what a given notebook is possible to do. That is, the FrontEnd will know whether this is an Enterprise Signed CDF ("Target" -> "PlayerPro"`) or just a simple standalone FreePlayer document.

This can affect things like cell evaluation so I'm assuming this notebook signature contains a flag for a FE that this NB is not editable.

I don't recall any way to do this but maybe there was available for authoring.

Again, that is a guess, maybe I missed something.

At the end, it is still just a text file which we can easily adapt but keep in mind that this may be against the terms and agreements.

• This is great! thanks – Andrea G May 8 '17 at 13:40
• could you comment why this is working? I opened the Option Inspector and both Deployed and Editable are already False and True in the original file – Andrea G May 8 '17 at 13:52
• @AndreaG Ok, edited, I hoped for more too :) sorry. – Kuba May 8 '17 at 19:32