Scripting Guide
NAURTECH WEB BROWSER AND TERMINAL EMULATION FOR WINDOWS CE AND WINDOWS MOBILE
CETerm Scripting Guide Page 94
Syntax
function OnSessionDisconnect ( session )
session – index of session which was disconnected by user.
Example
This example will switch to the next connected session when the current session
is disconnected. If there are no other connected sessions, then CETerm will exit.
/* OnSessionDisconnect */
function OnSessionDisconnect ( session )
{
// Switch to next connected session
CETerm.SendIDA( "IDA_SESSION_NEXTLIVE", 0 );
if (CETerm.ActiveSession == session)
{
// Still on current session, no others connected.
CETerm.PostIDA( "IDA_PROGRAM_EXIT", 0 );
}
}
4.13 THE ONSESSIONDISCONNECTED EVENT
The OnSessionDisconnected event is fired when a terminal emulation (TE)
session is disconnected by the remote host. The handler can be used to attempt
to reconnect to the host or perform other cleanup tasks.
Syntax
function OnSessionDisconnected ( session )
session – index of session which was disconnected by remote host.
Example
This example will check for RF coverage and attempt to reconnect if RF is
detected.
/* OnSessionDisconnected */
function OnSessionDisconnected ( session )