DialogReturn

DialogReturn[expr]
closes a dialog window, returning the expression expr from the dialog.

DialogReturn[]
closes a dialog window, returning Null.

DetailsDetails

ExamplesExamplesopen allclose all

Basic Examples  (2)Basic Examples  (2)

Put up a dialog window that returns 123 when the button is clicked:

In[1]:=
Click for copyable input
In[2]:=
Click for copyable input
Out[2]=

DialogReturn[] returns Null:

In[1]:=
Click for copyable input
In[2]:=
Click for copyable input
Out[2]//FullForm=
Introduced in 2007
(6.0)