This function starts a Microsoft Windows command line and passes a command to it. You can also specify to wait for the result of the command line.
system ( command, wait Y/N )
The result of this function is of type NUMBER. Refer to below for the meaning of the return codes.
This function has two parameters.
The result of the function is of type NUMBER and can be one of the following values:
<0 : |
The command could not be started. The values is equal to the negative error code. |
0: |
The command was started. |
>= 0: |
The command was started. The value is equal to the return code of the command. |
Example
NUMBER return_code
ASSIGN return_code := system("c:\winnt\system32\notepad.exe" ; "N")
#
@(return_code)
#
Note
Note that it only works if notepad is indeed located in c:\winnt\system32.