This query returns the status of an event that is loaded in memory. The information returned will be in the following format:
State <state>: <description> Error <last error number> Source <line of source code> Owner: <calling task>
where <state> is one of the following:
2: Stopped (due to IDLETASK)
4: Stopped due to run-time error
Returned value: 1, 2, 4
Event must be loaded in memory(after the execution of the OnEvent statement and while calling task is running).