This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)

SelectionMove

SelectionMove
moves the current selection in an open notebook in the front end in the direction dir by the specified unit.
SelectionMove
repeats the move n times.
  • Possible direction specifications are:
Nextmake the selection be the next unit of the specified type
Previousmake the selection be the previous unit of the specified type
Aftermake the selection be just after the end of the present unit
Beforemake the selection be just before the beginning of the present unit
Allmake the selection be the whole of the present unit
  • Possible unit specifications are:
Characterindividual character
Wordword or other token
Expressioncomplete subexpression
TextLineline of text
GraphicsContentsthe contents of a graphics object
Graphicscomplete graphics object
CellContentsthe contents of a cell
Cellcomplete cell
CellGroupcell group
EvaluationCellcell associated with the current evaluation
ButtonCellcell associated with any button that initiated the evaluation
GeneratedCellcell generated by the current evaluation
Notebookcomplete notebook
  • The front end will also usually highlight the region corresponding to the result.
  • With direction specifications and , SelectionMove will usually make the current selection be an insertion point between two units of the specified type. »
  • The defines the point after which output from the current evaluation will by default be placed.
Select the first cell after the initial selection position:
Select the third cell after the initial selection position:
Select the first cell after the initial selection position:
 
Select the third cell after the initial selection position:
Create a notebook:
Move the selection to the first letter:
Move the selection to the CellGroup:
Move the selection to the graphics within the cell:
Move the selection to the end of the notebook:
Normally, any selection is visibly displayed in the notebook window regardless of its location:
With AutoScroll set to False, the selection is offscreen:
SelectionMove regards inline cells as equivalent to words:
To emulate keyboard cursor movement, use a front end token such as "MoveNext":
SelectionMove can only select multiple cells as part of a CellGroup unit specification:
To select a series of individual cells, use a front end token such as :
New in 3 | Last modified in 6