Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
$\begingroup$You can do this with FrontEndTokenExecute["EvaluateInitialization"] but note that even if you make this Dynamic you will still need to enable Dynamic for that notebook before it will work.$\endgroup$
$\begingroup$By the way, placing FrontEndTokenExecute["EvaluateInitialization"] a the beginning of the notebook, cause a "running" loop when i click evaluate initialization cells from the menu$\endgroup$
$\begingroup$NotebookDynamicExpression is an option. Please read the documentation. This should not be in a cell as obviously that cell will be evaluated every time you run the initialization, which will re-run the initialization, etc.$\endgroup$
FrontEndTokenExecute["EvaluateInitialization"]
but note that even if you make thisDynamic
you will still need to enableDynamic
for that notebook before it will work. $\endgroup$NotebookDynamicExpression
is an option. Please read the documentation. This should not be in a cell as obviously that cell will be evaluated every time you run the initialization, which will re-run the initialization, etc. $\endgroup$