Link Search Menu Expand Document

Event Constructor

Explanation Initialize the Event object.
If you specify a reason, it initializes the Reason property.
If you specify eventName, it initializes the EventName property.
Call format var ev = new Event( [ reason [, eventName ] ] )
OR
var ev = new Event( eventName )
Added since Ver.4.0.0 and Mobile Ver.3.2.0
Return value Event object
Arguments integer reason Specify the event type numerically. For user-specific events, specify a value greater than UserEvent.
String eventName Specify the name of the event.
Exception None
Example of use
Function OnSampleEvent (e) {
    print ("Event.Reason =", e.Reason, "¥ n");
    print ("Event.EventName =", e.EventName, "¥ n");
    print ("Event.From.Name =", e.From.Name, "¥ n");
}
PostEvent (new Event (UserEvent + 1, "SampleEvent"));
Related item