DADiSP Worksheet Functions > Function Categories > Macro and Command File Functions > COMFILESTATUS
Returns the execution status of a command file.
COMFILESTATUS
An integer.
0: no command file running
1: command file is running
3: command file suspended
5: command file paused
Example of DADiSP as an ActiveX Server in Visual Basic:
Set DADiSP = CreateObject("DADiSP.Application")
DADiSP.Execute("Load('comfile.dsp')")
’’’ wait for command file to finish
While DADiSP.Execute("ComfileStatus")
Wend
The While statement effective pauses the Visual Basic program until the execution of the DADiSP command file is completed