Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Mathematica > Notebooks and Documents > Low-Level Notebook Programming > SelectionEvaluate >

SelectionEvaluate

SelectionEvaluate[notebook]
replaces the current selection in a notebook with the result obtained by evaluating the contents of the selection in the kernel.
SelectionEvaluate
sets the current selection after the evaluation to be as specified by sel.
  • The default for sel is .
  • Unless sel is None, the current selection after evaluation is complete will always be as specified by sel, even if you moved the selection interactively in the front end during the course of the evaluation.
Create a notebook and select an expression within it:
Evaluate the expression in place:
Create a notebook and select an expression within it:
In[1]:=
Click for copyable input
Evaluate the expression in place:
To evaluate an input cell and produce output beneath it, use SelectionEvaluateCreateCell:
New in 3
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF