$CurrentWebSession

$CurrentWebSession

gives the currently active web session used by WebExecute.

Details

Examples

Basic Examples  (1)

$CurrentWebSession is None initially:

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

Start a new web session:

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

$CurrentWebSession is the most recently started WebSessionObject:

In[3]:=
Click for copyable input
Out[3]=

WebExecute uses $CurrentWebSession when no other WebSessionObject is given:

In[4]:=
Click for copyable input
Out[4]=

Close the web session:

In[5]:=
Click for copyable input

$CurrentWebSession is None again:

In[6]:=
Click for copyable input
Out[6]=
Introduced in 2019
(12.0)