0
$\begingroup$

I have a code like this:

namep = StringJoin[name, ".pdf"]; 
nb1 = NotebookOpen[alg];
SelectionMove[nb1, All, Notebook];
FrontEndTokenExecute[nb1, "EvaluateNotebook"];
Do[Print[TabView[{datos -> grad[[i]], Graficos -> graf[[i]], 
Correlaciones -> grac}]], {i, diamindd, diamaxdd, step}];

But the Do instruction begins when the nb1 is still working and the print does not produce any: Part::partd: Part specification grad[[1]] is longer than depth of object.

How I can solve this?

Thanks

$\endgroup$
  • $\begingroup$ Perhaps you can adapt this: mathematica.stackexchange.com/questions/119422/… $\endgroup$ – Bill May 16 '18 at 19:59
  • $\begingroup$ Now I have: nb1 = NotebookOpen[alg]; NotebookEvaluate[nb1]; Do[Print[TabView[{datos -> grad[[i]], Graficos -> graf[[i]], Correlaciones -> grac}]], {i, diamindd, diamaxdd, step}]; but the program un the notebook and remains evaluating with no answer. Only I have answer if I write the Print in a separate cell. Thanks $\endgroup$ – jesus May 17 '18 at 1:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.