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

Documentation / Mathematica / The Mathematica Book / Principles of Mathematica / Manipulating Notebooks /

2.11.4 Manipulating the Front End from the Kernel

Manipulating global options in the front end.

Just like cells and notebooks, the complete Mathematica front end has various options, which you can look at and manipulate from the kernel.

This gives the object corresponding to the front end currently in use.

In[1]:= $FrontEnd


This gives the current directory used by the front end for notebook files.

In[2]:= Options[$FrontEnd, NotebookDirectory]


A few global options for the Mathematica front end.

By using NotebookWrite you can effectively input to the front end any ordinary text that you can enter on the keyboard. FrontEndTokenExecute allows you to send from the kernel any command that the front end can execute. These commands include both menu items and control sequences.

Executing a named command in the front end.

A few named commands that can be given to the front end. These commands usually correspond to menu items.