Occurs when the application is reset.
Object.OnReset()
The OnReset event syntax has the following parts:
Name |
Type |
Description |
Object |
AProgram, ADriver, ASystem |
Module object |
This event is called when the user select Reset command from the IDE run menu or when a Reset statement is called.
The sequence of OnReset event called is as follows:
Program.OnReset (if a program is currently running)
Driver(i).OnReset
System.OnReset
The following example shows the results of calling the reset statement inside a test:
* Program.OnInitTest
* Program.OnReset
* Driver2.OnReset
* Driver1.OnReset
* System.OnReset
* Program.OnEndTest
If the reset is called by pressing Reset command from the IDE button the application will be aborted exit and reloaded as shown here (no program was loaded in this example):
...Application aborted.
* Driver2.OnAbort
* Driver1.OnAbort
* System.OnAbort
* System.OnEndSystem
* Driver2.OnEnd
* Driver1.OnEnd
* System.OnEnd
...Application reset.
* Driver2.OnReset
* Driver1.OnReset
* System.OnReset
********************************************************************************
* System.OnInit
* Driver1.OnInit
* Driver2.OnInit
* System.OnInitSystem
The following is an example of one way to use the OnRest event:
Program.OnReset()
{
! ... program initialization code ...
print "Program "; Program.Name; " has been re-initialized after application reset."
}
Reset, Reset Events, About Module Events