An ALog control used for debugging output, trace statements.
ALog Public
The DebugLog is used by the Trace statement for debug output.
When running the application within the ATEasy environment the DebugLog variable is set to the ATEasy built-in Log window Debug tab log control. When running the application in standalone (executable) mode the DebugLog variable is set to Nothing.
If the Trace statement is used and the DebugLog is set to Nothing, then no output will be generated and the Trace statement will be ignored.
DebugLog is defined in build 134 or before as Const variable. In ATEasy build 134a or newer the Const is removed and the variable can be set to a user form log control, allowing the user to redirect the trace statement output to the form log control window (see the second example below).
The following example uses the DebugLog variable to debug output while running an application within the ATEasy:
Procedure StartDebug() : Void public
{
trace "Debug Log Started :";STime()
}
The following example sets the DebugLog variable to route the debug log output (trace) to a form log control:
Procedure OnInit() : void public
{
Load m_frmMain
DebugLog=m_frmMain.logDebug
trace "Debug Log Started "; SDate();" "; STime()
}
The following example determine if we are running the project from EXE:
if DebugLog=Nothing
! running executable
...
endif