Previous PageNext Page

5.2.3 Application Events

When an application starts, the Application_OnStart event occurs. The Application_OnEnd event occurs when the application shuts down. When the application starts or stops, the server looks in the Global.asa file (see below) to find the event scripts.
 

5.2.3.1 Application_OnStart Event

The Application_OnStart event occurs before the first session is created, before the Session_OnStart event (see below) occurs. Only the Server and Application built-in objects are available. Referencing the Session, Request, or Response objects in the Application_OnStart event will generate an error.
 

Syntax

<SCRIPT LANGUAGE=ScriptLanguage RUNAT=Server>

Sub Application_OnStart

. . .

End Sub

</SCRIPT>

Parameters

ScriptLanguage
Specifies the scripting language used to write the event script. It may be any supported scripting language, such as VBScript or JScript. If more than one event uses the same scripting language, they can be combined under a single set of <SCRIPT> tags.
Runat
Must be "Server".

5.2.3.2 Application_OnEnd Event

The Application_OnEnd event occurs when the application ends, after the Session_OnEnd event (see below). Only the Server and Application objects are available.
 

Syntax

<SCRIPT LANGUAGE=ScriptLanguage RUNAT=Server>

Sub Application_OnEnd

. . .

End Sub

</SCRIPT>

Parameters

ScriptLanguage
Specifies the scripting language used to write the event script. It may be any supported scripting language, such as VBScript or JScript. If more than one event uses the same scripting language, they can be combined under a single set of <SCRIPT> tags.
Runat
Must be "Server".

Copyright © 2000 Chili!Soft

Previous PageTop Of PageNext Page