3
$\begingroup$

How might I select the 1st Placeholder in a Notebook?

SelectionMove

Has no option.

Button["Click Here",
 NotebookWrite[
   InputNotebook[],
   ToBoxes[Unevaluated@Sum[Placeholder[m ], {t, 1, n}]],
   Placeholder];
 ]
$\endgroup$
1
$\begingroup$

This works for me in version 10.0.0 under Windows:

NotebookFind[EvaluationNotebook[], "\[Placeholder]"]

Since:

NotebookFind[obj,data] sets the current selection in the specified notebook object to be the next occurrence of data.

This must be placed at the top of the Notebook when it is run.

| improve this answer | |
$\endgroup$
  • $\begingroup$ It is a named Placeholder. But I believe I see. $\endgroup$ – William Sep 3 '14 at 2:45
  • $\begingroup$ @Liam I don't understand your comment. What do you mean? Were you not referring to \[Placeholder] as generated with Placeholder[]? $\endgroup$ – Mr.Wizard Sep 3 '14 at 2:48
  • $\begingroup$ I am. Posted example. Version doesn't work currently. $\endgroup$ – William Sep 3 '14 at 2:51

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.