RunSync Method



 
The RunSync method runs the application and returns an exit code after closing it.


Syntax

    [long] = SiteKiosk.ExternalApps.Item(index).RunSync(timeout)
Parameters
    timeout Long value that specifies the timeout period.
Return Value
    Returns a Long value containing the exit code.
Remarks
    Setting the timeout parameter to -1 means that there is an infinite period of time.

    If a time out occurres an exception will be thrown.

    External applications can be configured in the SiteKiosk configuration.
Examples
    The following example runs the application configured first and shows an alert window if a time out occurres.

    <SCRIPT TYPE="text/javascript">
    window.external.InitScriptInterface();
    try
    {
       myexitcode = SiteKiosk.ExternalApps.Item(1).RunSync(20);
    }
    catch(e)
    {
       alert("Time out");
    }
    </SCRIPT>
    

Applies to
    SiteKiosk v5.5 (and later versions).

Back to top